* [PATCH] orangefs: remove redundant assignment to variable ret
@ 2020-05-24 22:48 Colin King
2020-06-01 11:15 ` Mike Marshall
0 siblings, 1 reply; 2+ messages in thread
From: Colin King @ 2020-05-24 22:48 UTC (permalink / raw)
To: Mike Marshall, Martin Brandenburg, devel; +Cc: kernel-janitors, linux-kernel
From: Colin Ian King <colin.king@canonical.com>
The variable ret is being initialized with a value that is
never read and it is being updated later with a new value. The
initialization is redundant and can be removed.
Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
fs/orangefs/orangefs-mod.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/orangefs/orangefs-mod.c b/fs/orangefs/orangefs-mod.c
index c010c1fddafc..289b648ae196 100644
--- a/fs/orangefs/orangefs-mod.c
+++ b/fs/orangefs/orangefs-mod.c
@@ -79,7 +79,7 @@ DECLARE_WAIT_QUEUE_HEAD(orangefs_request_list_waitq);
static int __init orangefs_init(void)
{
- int ret = -1;
+ int ret;
__u32 i = 0;
if (op_timeout_secs < 0)
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] orangefs: remove redundant assignment to variable ret
2020-05-24 22:48 [PATCH] orangefs: remove redundant assignment to variable ret Colin King
@ 2020-06-01 11:15 ` Mike Marshall
0 siblings, 0 replies; 2+ messages in thread
From: Mike Marshall @ 2020-06-01 11:15 UTC (permalink / raw)
To: Colin King; +Cc: Martin Brandenburg, devel, kernel-janitors, LKML
Hi Colin... thanks for the patch, I have applied it
to the orangefs for-next tree...
-Mike
On Sun, May 24, 2020 at 6:48 PM Colin King <colin.king@canonical.com> wrote:
>
> From: Colin Ian King <colin.king@canonical.com>
>
> The variable ret is being initialized with a value that is
> never read and it is being updated later with a new value. The
> initialization is redundant and can be removed.
>
> Addresses-Coverity: ("Unused value")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> fs/orangefs/orangefs-mod.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/orangefs/orangefs-mod.c b/fs/orangefs/orangefs-mod.c
> index c010c1fddafc..289b648ae196 100644
> --- a/fs/orangefs/orangefs-mod.c
> +++ b/fs/orangefs/orangefs-mod.c
> @@ -79,7 +79,7 @@ DECLARE_WAIT_QUEUE_HEAD(orangefs_request_list_waitq);
>
> static int __init orangefs_init(void)
> {
> - int ret = -1;
> + int ret;
> __u32 i = 0;
>
> if (op_timeout_secs < 0)
> --
> 2.25.1
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-06-01 11:15 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-24 22:48 [PATCH] orangefs: remove redundant assignment to variable ret Colin King
2020-06-01 11:15 ` Mike Marshall
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).