How to find socket buffer size
Prasanta Sadhukhan <[email protected]>
| Newsgroups | gmane.os.netbsd.help |
|---|---|
| Message-ID | <[email protected]> |
Hi,
How can I find the default maximum socket buffer size in NetBSD?
For example, in Solaris it's 64KB and can be found using
s = open ("/dev/udp", O_RDWR);
if (s < 0) {
return dflt;
}
strncpy (buf, "udp_max_buf", sizeof(buf));
stri.ic_cmd = ND_GET;
stri.ic_timout = 0;
stri.ic_dp = buf;
stri.ic_len = sizeof(buf);
if (ioctl (s, I_STR, &stri) < 0) {
value = dflt;
} else {
value = atoi(buf);
I could not find any /dev/udp as such. Any clue?
Regards
Prasanta