aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Penkler <dpenkler@gmail.com>2024-12-04 15:57:13 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-12-04 16:58:33 +0100
commit1d8c2d4b89b40f49ef4a70dcb2eaea43695025ce (patch)
tree2bf7329f35a05bb41f3cc70119abb7e60d185042
parentstaging: gpib: Workaround for ppc build failure (diff)
downloadlinux-1d8c2d4b89b40f49ef4a70dcb2eaea43695025ce.tar.gz
linux-1d8c2d4b89b40f49ef4a70dcb2eaea43695025ce.zip
staging: gpib: Fix faulty workaround for assignment in if
This was detected by Coverity. Add the missing assignment in the else branch of the if Reported-by: Kees Bakker <kees@ijzerbout.nl> Fixes: fce79512a96a ("staging: gpib: Add LPVO DIY USB GPIB driver") Signed-off-by: Dave Penkler <dpenkler@gmail.com> Link: https://lore.kernel.org/r/20241204145713.11889-5-dpenkler@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/gpib/lpvo_usb_gpib/lpvo_usb_gpib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/gpib/lpvo_usb_gpib/lpvo_usb_gpib.c b/drivers/staging/gpib/lpvo_usb_gpib/lpvo_usb_gpib.c
index 796c3a5be545..267651a15fa0 100644
--- a/drivers/staging/gpib/lpvo_usb_gpib/lpvo_usb_gpib.c
+++ b/drivers/staging/gpib/lpvo_usb_gpib/lpvo_usb_gpib.c
@@ -901,7 +901,7 @@ static int usb_gpib_read(gpib_board_t *board,
} else {
/* we are in the closing <DLE><ETX> sequence */
-
+ c = nc;
if (c == ETX) {
c = one_char(board, &b);
if (c == ACK) {