Fix a bug in the userland rpc library, where it would use a
authorrmacklem <rmacklem@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Sun, 10 Apr 2011 14:11:07 +0000 (14:11 +0000)
committerrmacklem <rmacklem@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Sun, 10 Apr 2011 14:11:07 +0000 (14:11 +0000)
commit5f867549fe92c4d57a3a2a0f26757b9ceba52c4f
tree89efb7b1bf5b41e4796cb214dfd3ca4a099de140
parent7524e4aaf0bf1cfa9fa8a41f3df03b0f53afca96
Fix a bug in the userland rpc library, where it would use a
negative return value from write to update its position in
a buffer. The patch, courtesy of Andrey Simonenko, also simplifies
a conditional by removing the "i != cnt" clause, since it is
always true at this point in the code. The bug caused problems
for mountd, when it generated a large reply to an exports RPC
request.

Submitted by: simon at comsys.ntu-kpi.kiev.ua
MFC after: 2 weeks

git-svn-id: http://svn.freebsd.org/base/head@220519 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
lib/libc/rpc/svc_vc.c