diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-10-12 21:01:03 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-10-12 21:01:03 -0700 |
commit | 80c217ec6073e1d80fbe256e1bb88e8180d8602e (patch) | |
tree | c359450092029153209d85095d8a115391dfc5b2 /src/library_fs.js | |
parent | 5e6b5e313cb2fa9c699934df72a7c975d1d02ad2 (diff) |
use stackTrace in various places
Diffstat (limited to 'src/library_fs.js')
-rw-r--r-- | src/library_fs.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/library_fs.js b/src/library_fs.js index dc5c20f8..8f68b395 100644 --- a/src/library_fs.js +++ b/src/library_fs.js @@ -37,6 +37,7 @@ mergeInto(LibraryManager.library, { } } this.message = ERRNO_MESSAGES[errno]; + this.stack = stackTrace(); }; ErrnoError.prototype = new Error(); ErrnoError.prototype.constructor = ErrnoError; @@ -44,7 +45,7 @@ mergeInto(LibraryManager.library, { }()), handleFSError: function(e) { - if (!(e instanceof FS.ErrnoError)) throw e + ' : ' + new Error().stack; + if (!(e instanceof FS.ErrnoError)) throw e + ' : ' + stackTrace(); return ___setErrNo(e.errno); }, |