forked from KolibriOS/kolibrios
Fixed socket_ring_write in net branch.
git-svn-id: svn://kolibrios.org@2404 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
4aee41218a
commit
946e05cb81
@ -1165,15 +1165,14 @@ SOCKET_ring_write:
|
|||||||
|
|
||||||
ret
|
ret
|
||||||
|
|
||||||
.too_large:
|
.too_large: ; update size, we will fill buffer completely
|
||||||
mov ecx, SOCKET_MAXDATA ; calculate number of bytes available in buffer
|
sub [eax + RING_BUFFER.size], SOCKET_MAXDATA
|
||||||
sub ecx, [eax + RING_BUFFER.size]
|
sub ecx, [eax + RING_BUFFER.size]
|
||||||
jae .full
|
mov [eax + RING_BUFFER.size], SOCKET_MAXDATA
|
||||||
|
|
||||||
mov [eax + RING_BUFFER.size], SOCKET_MAXDATA ; update size, we will fill buffer completely
|
test ecx, ecx
|
||||||
jmp .copy
|
jnz .copy
|
||||||
|
|
||||||
.full:
|
|
||||||
DEBUGF 2,"SOCKET_ring_write: ring buffer is full!\n"
|
DEBUGF 2,"SOCKET_ring_write: ring buffer is full!\n"
|
||||||
xor ecx, ecx
|
xor ecx, ecx
|
||||||
ret
|
ret
|
||||||
|
Loading…
Reference in New Issue
Block a user