This is the mail archive of the java-patches@sources.redhat.com 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]

Re: Patch: Fix last patch and convert throws


Bryce> This patch fixes the error in my last patch, and also converts
Bryce> all the JvThrow() calls in java.net to throw statements, for
Bryce> consistency.

Bryce> -  if (::setsockopt (fnum, level, opname, ptr, len) == 0)
Bryce> +  if (::setsockopt (fnum, level, opname, ptr, len) != 0)
Bryce>      return;
Bryce> +
Bryce> +  char* strerr = strerror (errno);
Bryce> +  throw new java::io::IOException (JvNewStringUTF (strerr));

I think this hunk is wrong.
`setsockopt' returns 0 if it succeeds.

Tom

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