Date: Sat, 8 Jan 2005 17:26:29 +0000 (GMT) From: Robert Watson <rwatson@freebsd.org> To: Ivan Voras <ivoras@fer.hr> Cc: hackers@freebsd.org Subject: Re: Raw sockets problem? Message-ID: <Pine.NEB.3.96L.1050108172415.43829E-100000@fledge.watson.org> In-Reply-To: <41DFF957.9040506@fer.hr>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 8 Jan 2005, Ivan Voras wrote: > I've just noticed I can't create a raw socket on 5.3-RELEASE, while the > same code works on 5.2. I get 'Protocol not supported' error on code > like this: I've not got a 5.2 box on hand, but this appears not to work on 4.x. There isn't a domain handler for AF_LINK, so you shouldn't be able to create a socket of that type, so if it was possible in 5.2, it was likely a bug. Robert N M Watson > > #include <stdio.h> > #include <stdlib.h> > #include <string.h> > #include <sys/socket.h> > #include <errno.h> > > void main() { > int sock = socket(AF_LINK, SOCK_RAW, 0); > if (sock < 0) > printf(strerror(errno)); > } > > Code like this *seems* ok (and I'm sure it worked on 5.2)... why does it > fail now? > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.NEB.3.96L.1050108172415.43829E-100000>