Re: [PATCH] VSOCK: remove unnecessary ternary operator on return value

2017-03-28 Thread David Miller
From: Colin King Date: Tue, 28 Mar 2017 16:54:24 +0100 > From: Colin Ian King > > Rather than assign the positive errno values to ret and then > checking if it is positive and flip the sign, just set ret to > be the -ve errno value. > > Detected by CoverityScan, CID#986649 ("Logically Dead Cod

Re: [PATCH] VSOCK: remove unnecessary ternary operator on return value

2017-03-28 Thread walter harms
Am 28.03.2017 17:54, schrieb Colin King: > From: Colin Ian King > > Rather than assign the positive errno values to ret and then > checking if it is positive and flip the sign, just set ret to > be the -ve errno value. > > Detected by CoverityScan, CID#986649 ("Logically Dead Code") > > Signe

[PATCH] VSOCK: remove unnecessary ternary operator on return value

2017-03-28 Thread Colin King
From: Colin Ian King Rather than assign the positive errno values to ret and then checking if it is positive and flip the sign, just set ret to be the -ve errno value. Detected by CoverityScan, CID#986649 ("Logically Dead Code") Signed-off-by: Colin Ian King --- net/vmw_vsock/vmci_transport.c