Fix for warning: 'res' may be used uninitialized in this function
[mirror/scst/.git] / iscsi-scst / kernel / nthread.c
index 8b09985..9d10b93 100644 (file)
@@ -847,6 +847,7 @@ static void process_read_io(struct iscsi_conn *conn, int *closed)
                        break;
 
                case RX_END:
+                       res = 0;
                        if (unlikely(conn->read_size != 0)) {
                                PRINT_CRIT_ERROR("%d %x %d", res,
                                        cmnd_opcode(cmnd), conn->read_size);