Kernel: fmount: Return failure instead of panicking when a device cannot
authorWill Sowerbutts <will@sowerbutts.com>
Fri, 6 Jan 2017 19:22:50 +0000 (19:22 +0000)
committerWill Sowerbutts <will@sowerbutts.com>
Sun, 8 Jan 2017 23:05:11 +0000 (23:05 +0000)
be opened.

Kernel/filesys.c

index 678755d..48be4fc 100644 (file)
@@ -1106,7 +1106,7 @@ bool fmount(uint16_t dev, inoptr ino, uint16_t flags)
     struct filesys *fp;
 
     if(d_open(dev, 0) != 0)
-        panic(PANIC_FMOUNT_NOPEN);
+        return true;    /* Bad device */
 
     m = newfstab();
     if (m == NULL) {