summaryrefslogtreecommitdiff
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
parent80242c4a9d50e71a4df1b7fa19b922ac88aab22b (diff)
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) {