Make dg_echo return up to the first 65536 bytes of a datagram.

The patch I used isn't quite the one Lars suggested, but the size
of the largest datagram you can recv isn't #defined anywhere, and
probably isn't even bounded for some protocols.

PR:		25050
Submitted by:	Lars Eggert <larse@isi.edu>
This commit is contained in:
David Malone 2001-05-26 14:40:39 +00:00
parent 74e14107c6
commit d0847e9377

View File

@ -267,7 +267,7 @@ echo_dg(s, sep) /* Echo service -- echo data back */
int s;
struct servtab *sep;
{
char buffer[BUFSIZE];
char buffer[65536]; /* Should be sizeof(max datagram). */
int i;
socklen_t size;
struct sockaddr_storage ss;