orangefs: remove redundant assignment to variable buffer_index
authorColin Ian King <colin.king@canonical.com>
Sat, 11 May 2019 13:27:00 +0000 (14:27 +0100)
committerMike Marshall <hubcap@omnibond.com>
Thu, 11 Jul 2019 16:52:37 +0000 (12:52 -0400)
The variable buffer_index is being initialized however this is never
read and later it is being reassigned to a new value. The initialization
is redundant and hence can be removed.

Addresses-Coverity: ("Unused Value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Mike Marshall <hubcap@omnibond.com>
fs/orangefs/file.c

index a35c170..80f06ee 100644 (file)
@@ -52,7 +52,7 @@ ssize_t wait_for_direct_io(enum ORANGEFS_io_type type, struct inode *inode,
        struct orangefs_inode_s *orangefs_inode = ORANGEFS_I(inode);
        struct orangefs_khandle *handle = &orangefs_inode->refn.khandle;
        struct orangefs_kernel_op_s *new_op = NULL;
-       int buffer_index = -1;
+       int buffer_index;
        ssize_t ret;
        size_t copy_amount;