aboutsummaryrefslogtreecommitdiff
path: root/error.cgi
diff options
context:
space:
mode:
Diffstat (limited to 'error.cgi')
-rwxr-xr-xerror.cgi15
1 files changed, 9 insertions, 6 deletions
diff --git a/error.cgi b/error.cgi
index 8caea1f..91058be 100755
--- a/error.cgi
+++ b/error.cgi
@@ -91,12 +91,15 @@ $h << "</div></div>"
$h.out($cgi)
-tmpfile = "/tmp/error.#{rand(10000)}"
-File.open(tmpfile,"w"){|f|
- f << errorstr
-}
+if AUTO_SEND_REPORT
+ tmpfile = "/tmp/error.#{rand(10000)}"
+ File.open(tmpfile,"w"){|f|
+ f << errorstr
+ }
-`mail -s "Bug in dudle" #{BUGREPORTMAIL} < #{tmpfile}`
+ `mail -s "Bug in dudle" #{BUGREPORTMAIL} < #{tmpfile}`
-File.delete(tmpfile)
+ File.delete(tmpfile)
+
+end