|
@@ -251,12 +251,12 @@ int venus_open(struct super_block *sb, struct CodaFid *fid,
|
|
|
insize = SIZE(open_by_fd);
|
|
|
UPARG(CODA_OPEN_BY_FD);
|
|
|
|
|
|
- inp->coda_open.VFid = *fid;
|
|
|
- inp->coda_open.flags = flags;
|
|
|
+ inp->coda_open_by_fd.VFid = *fid;
|
|
|
+ inp->coda_open_by_fd.flags = flags;
|
|
|
|
|
|
- error = coda_upcall(coda_sbp(sb), insize, &outsize, inp);
|
|
|
-
|
|
|
- *fh = outp->coda_open_by_fd.fh;
|
|
|
+ error = coda_upcall(coda_sbp(sb), insize, &outsize, inp);
|
|
|
+ if (!error)
|
|
|
+ *fh = outp->coda_open_by_fd.fh;
|
|
|
|
|
|
CODA_FREE(inp, insize);
|
|
|
return error;
|