diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2016-03-19 09:08:10 +0100 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2016-03-19 09:08:10 +0100 |
commit | 233d12d8b1916eae5bae230dc965045adb89a173 (patch) | |
tree | 7cbaff56cead511af044c4dcedf208fed0094035 /server | |
parent | 8c9c1942f6b5675cfca802e2f707bef3c217afbf (diff) | |
download | PeerTube-233d12d8b1916eae5bae230dc965045adb89a173.tar.gz PeerTube-233d12d8b1916eae5bae230dc965045adb89a173.tar.zst PeerTube-233d12d8b1916eae5bae230dc965045adb89a173.zip |
Fix exception log of the webtorrent process
Diffstat (limited to 'server')
-rw-r--r-- | server/lib/webtorrent.js | 2 | ||||
-rw-r--r-- | server/lib/webtorrentProcess.js | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/webtorrent.js b/server/lib/webtorrent.js index 455b086a3..e2e2586f9 100644 --- a/server/lib/webtorrent.js +++ b/server/lib/webtorrent.js | |||
@@ -53,7 +53,7 @@ function create (options, callback) { | |||
53 | }) | 53 | }) |
54 | 54 | ||
55 | ipc.server.on(processKey + '.exception', function (data) { | 55 | ipc.server.on(processKey + '.exception', function (data) { |
56 | throw new Error('Received exception error from webtorrent process.' + data.exception) | 56 | throw new Error('Received exception error from webtorrent process : ' + data.exception) |
57 | }) | 57 | }) |
58 | 58 | ||
59 | const webtorrent_process = spawn(pathUtils.join(__dirname, 'webtorrentProcess.js'), host, port, { detached: true }) | 59 | const webtorrent_process = spawn(pathUtils.join(__dirname, 'webtorrentProcess.js'), host, port, { detached: true }) |
diff --git a/server/lib/webtorrentProcess.js b/server/lib/webtorrentProcess.js index c68e97ee4..7889e7128 100644 --- a/server/lib/webtorrentProcess.js +++ b/server/lib/webtorrentProcess.js | |||
@@ -83,7 +83,7 @@ function webtorrent (args) { | |||
83 | }) | 83 | }) |
84 | 84 | ||
85 | process.on('uncaughtException', function (e) { | 85 | process.on('uncaughtException', function (e) { |
86 | ipc.of[nodeKey].emit(processKey + '.exception', { exception: e }) | 86 | ipc.of[nodeKey].emit(processKey + '.exception', { exception: e.toString() }) |
87 | }) | 87 | }) |
88 | } | 88 | } |
89 | 89 | ||