Skip to content
Snippets Groups Projects
Commit 1a9845b4 authored by Michael Walle's avatar Michael Walle Committed by Wolfgang Denk
Browse files

netconsole: support packets longer than 512 bytes


Esp. while printing the environment the output is usually longer than 512
bytes. Instead of cutting the message, send multiple 512 bytes packets.

Signed-off-by: default avatarMichael Walle <michael@walle.cc>
Acked-by: default avatarMike Frysinger <vapier@gentoo.org>
parent ca366d0e
No related branches found
No related tags found
No related merge requests found
......@@ -189,10 +189,13 @@ static void nc_puts(const char *s)
return;
output_recursion = 1;
if ((len = strlen (s)) > 512)
len = 512;
nc_send_packet (s, len);
len = strlen(s);
while (len) {
int send_len = min(len, 512);
nc_send_packet(s, send_len);
len -= send_len;
s += send_len;
}
output_recursion = 0;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment