* java/nat/natPlainSocketImpl.cc (write): Abort loop on error.

From-SVN: r51231
This commit is contained in:
Jeff Sturm 2002-03-23 15:05:30 +00:00 committed by Jeff Sturm
parent 5f7ed64a15
commit 48e4beeca8
2 changed files with 6 additions and 0 deletions

View File

@ -1,3 +1,7 @@
2002-03-23 Jeff Sturm <jsturm@one-point.com>
* java/nat/natPlainSocketImpl.cc (write): Abort loop on error.
2002-03-20 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
* posix-threads.cc (_Jv_ThreadSelf_out_of_line): Use write_barrier,

View File

@ -450,6 +450,7 @@ java::net::PlainSocketImpl::write(jint b)
// Some errors should not cause exceptions.
if (errno != ENOTCONN && errno != ECONNRESET && errno != EBADF)
throw new java::io::IOException (JvNewStringUTF (strerror (errno)));
break;
}
}
}
@ -481,6 +482,7 @@ java::net::PlainSocketImpl::write(jbyteArray b, jint offset, jint len)
// Some errors should not cause exceptions.
if (errno != ENOTCONN && errno != ECONNRESET && errno != EBADF)
throw new java::io::IOException (JvNewStringUTF (strerror (errno)));
break;
}
written += r;
len -= r;