Re: [Xen-devel] [PATCH][next] xen/gntdev: remove redundant non-zero check on ret

2019-11-11 Thread Colin Ian King
On 11/11/2019 13:17, Jürgen Groß wrote: > On 11.11.19 13:31, Colin Ian King wrote: >> On 11/11/2019 12:25, Jürgen Groß wrote: >>> On 11.11.19 13:20, Colin King wrote: From: Colin Ian King The non-zero check on ret is always going to be false because ret was initialized as zero

Re: [Xen-devel] [PATCH][next] xen/gntdev: remove redundant non-zero check on ret

2019-11-11 Thread Jürgen Groß
On 11.11.19 13:31, Colin Ian King wrote: On 11/11/2019 12:25, Jürgen Groß wrote: On 11.11.19 13:20, Colin King wrote: From: Colin Ian King The non-zero check on ret is always going to be false because ret was initialized as zero and the only place it is set to non-zero contains a return path

Re: [Xen-devel] [PATCH][next] xen/gntdev: remove redundant non-zero check on ret

2019-11-11 Thread Colin Ian King
On 11/11/2019 12:25, Jürgen Groß wrote: > On 11.11.19 13:20, Colin King wrote: >> From: Colin Ian King >> >> The non-zero check on ret is always going to be false because >> ret was initialized as zero and the only place it is set to >> non-zero contains a return path before the non-zero check.

Re: [Xen-devel] [PATCH][next] xen/gntdev: remove redundant non-zero check on ret

2019-11-11 Thread Jürgen Groß
On 11.11.19 13:20, Colin King wrote: From: Colin Ian King The non-zero check on ret is always going to be false because ret was initialized as zero and the only place it is set to non-zero contains a return path before the non-zero check. Hence the check is redundant and can be removed.

[Xen-devel] [PATCH][next] xen/gntdev: remove redundant non-zero check on ret

2019-11-11 Thread Colin King
From: Colin Ian King The non-zero check on ret is always going to be false because ret was initialized as zero and the only place it is set to non-zero contains a return path before the non-zero check. Hence the check is redundant and can be removed. Addresses-Coverity: ("Logically dead code")