aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2014-12-09 13:38:55 +0100
committerDaniel Stenberg <daniel@haxx.se>2014-12-09 15:47:28 +0100
commitfc32b813820e440e86fcae85ed9d2185e61efcaf (patch)
treed80556f53b494d84915f2141610fb76b2a262913 /lib
parent6ea4ee94f96cda494c493fadd9d445d2fd202834 (diff)
smb: fix unused return code warning
Diffstat (limited to 'lib')
-rw-r--r--lib/smb.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/lib/smb.c b/lib/smb.c
index 079d9c706..4d556488e 100644
--- a/lib/smb.c
+++ b/lib/smb.c
@@ -719,9 +719,13 @@ static CURLcode smb_request_state(struct connectdata *conn, bool *done)
sizeof(struct smb_header) + 11));
off = smb_swap16(*(unsigned short *)((char *)msg +
sizeof(struct smb_header) + 13));
- if(len > 0)
- Curl_client_write(conn, CLIENTWRITE_BODY,
- (char *)msg + off + sizeof(unsigned int), len);
+ if(len > 0) {
+ result = Curl_client_write(conn, CLIENTWRITE_BODY,
+ (char *)msg + off + sizeof(unsigned int),
+ len);
+ if(result)
+ return result;
+ }
conn->data->req.bytecount += len;
conn->data->req.offset += len;
Curl_pgrsSetDownloadCounter(conn->data, conn->data->req.bytecount);