diff options
-rw-r--r-- | src/library.js | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/library.js b/src/library.js index 52b1fc8e..48137540 100644 --- a/src/library.js +++ b/src/library.js @@ -8559,7 +8559,13 @@ LibraryManager.library = { return -1; } var arg = {{{ makeGetValue('varargs', '0', 'i32') }}}; - return FS.ioctl(stream, request, arg); + + try { + return FS.ioctl(stream, request, arg); + } catch (e) { + FS.handleFSError(e); + return -1; + } }, #endif |