comparison cli-agentfwd.c @ 1062:210982935887 coverity

merge
author Matt Johnston <matt@ucc.asn.au>
date Mon, 02 Mar 2015 21:17:41 +0800
parents 16584026a1f0
children 750ec4ec4cbe
comparison
equal deleted inserted replaced
1052:e40d1b63b6a6 1062:210982935887
153 if (readlen > MAX_AGENT_REPLY) { 153 if (readlen > MAX_AGENT_REPLY) {
154 TRACE(("agent reply is too big")); 154 TRACE(("agent reply is too big"));
155 goto out; 155 goto out;
156 } 156 }
157 157
158 buf_resize(inbuf, readlen); 158 inbuf = buf_resize(inbuf, readlen);
159 buf_setpos(inbuf, 0); 159 buf_setpos(inbuf, 0);
160 ret = atomicio(read, fd, buf_getwriteptr(inbuf, readlen), readlen); 160 ret = atomicio(read, fd, buf_getwriteptr(inbuf, readlen), readlen);
161 if ((size_t)ret != readlen) { 161 if ((size_t)ret != readlen) {
162 TRACE(("read of data failed for agent_request")) 162 TRACE(("read of data failed for agent_request"))
163 goto out; 163 goto out;