зеркало из https://github.com/mono/ikvm-fork.git
Don't return -1 when attempting to read 0 bytes.
This commit is contained in:
Родитель
fa434bbd04
Коммит
2da6e524b5
|
@ -267,6 +267,10 @@ class Net { // package-private
|
|||
|
||||
private static int readImpl(FileDescriptor fd, byte[] buf, int offset, int length) throws IOException
|
||||
{
|
||||
if (length == 0)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
try
|
||||
{
|
||||
if (false) throw new cli.System.Net.Sockets.SocketException();
|
||||
|
|
Загрузка…
Ссылка в новой задаче