2017-02-13 18:46:19 +00:00
|
|
|
<html>
|
|
|
|
<body>
|
|
|
|
<script type="text/javascript" charset="utf-8">
|
|
|
|
|
|
|
|
const {port} = require('url').parse(window.location.href, true).query
|
2017-04-19 23:32:43 +00:00
|
|
|
const {crashReporter, ipcRenderer} = require('electron')
|
2017-02-13 18:46:19 +00:00
|
|
|
|
|
|
|
crashReporter.start({
|
|
|
|
productName: 'Zombies',
|
|
|
|
companyName: 'Umbrella Corporation',
|
|
|
|
submitURL: 'http://127.0.0.1:' + port,
|
|
|
|
uploadToServer: true,
|
|
|
|
ignoreSystemCrashHandler: true,
|
|
|
|
extra: {
|
2017-02-13 18:52:40 +00:00
|
|
|
extra1: 'extra1',
|
|
|
|
extra2: 'initial',
|
|
|
|
extra3: 'extra3'
|
2017-02-13 18:46:19 +00:00
|
|
|
}
|
|
|
|
})
|
|
|
|
|
2017-04-19 23:32:43 +00:00
|
|
|
if (process.platform === 'win32') {
|
|
|
|
ipcRenderer.sendSync('crash-service-pid', crashReporter._crashServiceProcess.pid)
|
|
|
|
}
|
|
|
|
|
2017-02-13 18:46:19 +00:00
|
|
|
setImmediate(() => {
|
2017-02-13 19:15:40 +00:00
|
|
|
if (process.platform === 'darwin') {
|
2017-12-07 19:26:57 +00:00
|
|
|
crashReporter.addExtraParameter('extra2', 'extra2')
|
|
|
|
crashReporter.removeExtraParameter('extra3')
|
2017-02-13 18:46:19 +00:00
|
|
|
} else {
|
|
|
|
crashReporter.start({
|
|
|
|
productName: 'Zombies',
|
|
|
|
companyName: 'Umbrella Corporation',
|
|
|
|
submitURL: 'http://127.0.0.1:' + port,
|
|
|
|
uploadToServer: true,
|
|
|
|
ignoreSystemCrashHandler: true,
|
|
|
|
extra: {
|
2017-02-13 18:52:40 +00:00
|
|
|
extra1: 'extra1',
|
|
|
|
extra2: 'extra2'
|
2017-02-13 18:46:19 +00:00
|
|
|
}
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
setImmediate(() => {
|
|
|
|
process.crash()
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
</script>
|
|
|
|
</body>
|
|
|
|
</html>
|