From c75396e23a50a144de6d08d57304c1803722ead2 Mon Sep 17 00:00:00 2001 From: Simon Wilkinson Date: Tue, 2 Feb 2010 00:03:04 +0000 Subject: [PATCH] Linux: Fix breakage in llseek error handling Commit 7a5cee30cc5f0e6d5780387633ce2b46608fd5fb changed the way that errors from llseek are dealt with. Unfortunately, it is missing some all important bracing, and so we end up going down the error path, even when the llseek succeeds. My fault. Sorry. Change-Id: I03061ba0663b610a8fb73a08d257f6d786795076 Reviewed-on: http://gerrit.openafs.org/1194 Reviewed-by: Marc Dionne Tested-by: Marc Dionne Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- src/afs/LINUX/osi_file.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/afs/LINUX/osi_file.c b/src/afs/LINUX/osi_file.c index e1a11fb3b..e3228279d 100644 --- a/src/afs/LINUX/osi_file.c +++ b/src/afs/LINUX/osi_file.c @@ -386,9 +386,10 @@ osi_rdwr(struct osi_file *osifile, uio_t * uiop, int rw) /* seek to the desired position. Return -1 on error. */ if (filp->f_op->llseek) { - if (filp->f_op->llseek(filp, (loff_t) uiop->uio_offset, 0) != uiop->uio_offset) + if (filp->f_op->llseek(filp, (loff_t) uiop->uio_offset, 0) != uiop->uio_offset) { code = -1; goto out; + } } else filp->f_pos = uiop->uio_offset; -- 2.39.5