diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2011-02-06 17:42:43 -0500 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2011-02-06 17:42:43 -0500 |
commit | ffb9c06dee656002319e2e14b3beafea9060bbfc (patch) | |
tree | ad41ed3d04a32b854eda46dbf8b3e48c2e58bf13 | |
parent | b943978902bd31317839f5cdcc97a957e4f408b3 (diff) | |
download | pfsense-ffb9c06dee656002319e2e14b3beafea9060bbfc.zip pfsense-ffb9c06dee656002319e2e14b3beafea9060bbfc.tar.gz |
Include anonymous machine information in bug report including:
Crash report begins. Anonymous machine information:
i386
8.1-RELEASE-p2
FreeBSD 8.1-RELEASE-p2 #1: Sun Feb 6 05:07:27 EST 2011 sullrich@FreeBSD_8.0_pfSense_2.0-snaps.pfsense.org:/usr/obj.pfSense/usr/pfSensesrc/src/sys/pfSense_SMP.8
Crash report details:
-rwxr-xr-x | usr/local/www/crash_reporter.php | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/usr/local/www/crash_reporter.php b/usr/local/www/crash_reporter.php index 06f3bdf..785ed02 100755 --- a/usr/local/www/crash_reporter.php +++ b/usr/local/www/crash_reporter.php @@ -77,6 +77,12 @@ function output_crash_reporter_html($crash_reports) { $pgtitle = array(gettext("Diagnostics"),gettext("Crash reporter")); include('head.inc'); +$crash_report_header = "Crash report begins. Anonymous machine information:\n\n"; +$crash_report_header .= php_uname("m") . "\n"; +$crash_report_header .= php_uname("r") . "\n"; +$crash_report_header .= php_uname("v") . "\n"; +$crash_report_header .= "\nCrash report details:\n\n"; + ?> <body link="#0000CC" vlink="#0000CC" alink="#0000CC"> @@ -88,6 +94,7 @@ include('head.inc'); <?php if (gettext($_POST['Submit']) == "Yes") { echo gettext("Processing..."); + file_put_contents("/var/crash/crashreport_header.txt", $crash_report_header); exec("/usr/bin/gzip /var/crash/*"); $files_to_upload = glob("/var/crash/*"); echo "<p/>"; @@ -108,7 +115,8 @@ include('head.inc'); exit; } else { $crash_files = glob("/var/crash/*"); - if(is_array($crash_files)) + $crash_reports .= $crash_report_header; + if(is_array($crash_files)) foreach($crash_files as $cf) $crash_reports .= file_get_contents($cf); else |