[VFATLIB] Only attempt to clear the dirty set bit in rw mode.
authorPierre Schweitzer <pierre@reactos.org>
Mon, 28 May 2018 07:00:13 +0000 (09:00 +0200)
committerPierre Schweitzer <pierre@reactos.org>
Mon, 28 May 2018 17:37:56 +0000 (19:37 +0200)
sdk/lib/fslib/vfatlib/check/boot.c

index a1fd58a..8596e2b 100644 (file)
@@ -294,9 +294,11 @@ static char print_fat_dirty_state(void)
     if (interactive) {
        printf("1) Remove dirty bit\n" "2) No action\n");
        return get_key("12", "?");
-    } else
+    } else if (rw) {
        printf(" Automatically removing dirty bit.\n");
     return '1';
+    }
+    return '2';
 }
 
 static void check_fat_state_bit(DOS_FS * fs, void *b)