aboutsummaryrefslogtreecommitdiff
path: root/src/libfs/write.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libfs/write.c')
-rw-r--r--src/libfs/write.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libfs/write.c b/src/libfs/write.c
index bae2083e..5da27d12 100644
--- a/src/libfs/write.c
+++ b/src/libfs/write.c
@@ -24,7 +24,8 @@ _fspwrite(Fid *fid, void *buf, long n, vlong offset)
tx.count = n;
tx.data = buf;
- fsrpc(fid->fs, &tx, &rx, &freep);
+ if(fsrpc(fid->fs, &tx, &rx, &freep) < 0)
+ return -1;
if(rx.type == Rerror){
werrstr("%s", rx.ename);
free(freep);