This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Patch: IP_MULTICAST_LOOP support


>>>>> "Anthony" == Anthony Green <green@redhat.com> writes:

Anthony> I don't really understand networking, but a little app I was
Anthony> trying to run a while ago complained about this missing
Anthony> support.  This is my best guess at the right thing to do.
Anthony> Comments?

Anthony> +	jbyteArray haddress = inetaddr->addr;
Anthony> +	jbyte *bytes = elements (haddress);
Anthony> +	int len = haddress->length;

It doesn't look like these are used...?

Anthony> +	if (::setsockopt (native_fd, level, opname, (char *) &val,
Anthony> +			  val_len) != 0)
Anthony> +	  goto error;

According to this page:

http://www.linux.org/docs/ldp/howto/Multicast-HOWTO-6.html

... the 'val' argument must be an 'unsigned char'.  So, I suspect the
above would fail on a big-endian machine.  (Though I am not an expert
here by any stretch.)

I wonder whether any of the other code here suffers from this bug.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]