summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Rettberg2019-03-25 14:33:05 +0100
committerSimon Rettberg2019-03-25 14:33:05 +0100
commit4c0f8148be1008c606f5b158dd643132f50a24dd (patch)
tree0f2915e257e346fee65f7ab56f6a0eb34dffd6bf
parent[inc/Trigger] Wait for taskmanager on bootup (diff)
downloadslx-admin-4c0f8148be1008c606f5b158dd643132f50a24dd.tar.gz
slx-admin-4c0f8148be1008c606f5b158dd643132f50a24dd.tar.xz
slx-admin-4c0f8148be1008c606f5b158dd643132f50a24dd.zip
[api/init] Add logging function for crashes
-rw-r--r--apis/init.inc.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/apis/init.inc.php b/apis/init.inc.php
index 617114d7..e0dcf707 100644
--- a/apis/init.inc.php
+++ b/apis/init.inc.php
@@ -6,4 +6,10 @@
if (!isLocalExecution())
exit(0);
+if (($report = Request::get('crashreport', false, 'string')) !== false) {
+ $details = file_get_contents($report);
+ EventLog::failure('Problems during bootup hook', $details);
+ exit(0);
+}
+
Event::systemBooted();