summaryrefslogtreecommitdiffstats
path: root/perl-install/standalone/drakbug
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2007-08-01 20:50:00 +0000
committerThierry Vignaud <tv@mandriva.org>2007-08-01 20:50:00 +0000
commit9becc48da70169c2a45f09f945dd7f4bd67a3fce (patch)
tree9fe0620777fcbff03b08813c873a77b87f1ae748 /perl-install/standalone/drakbug
parent5ee586ad6c3f17f79370d63440bc26fb7549baa6 (diff)
downloaddrakx-backup-do-not-use-9becc48da70169c2a45f09f945dd7f4bd67a3fce.tar
drakx-backup-do-not-use-9becc48da70169c2a45f09f945dd7f4bd67a3fce.tar.gz
drakx-backup-do-not-use-9becc48da70169c2a45f09f945dd7f4bd67a3fce.tar.bz2
drakx-backup-do-not-use-9becc48da70169c2a45f09f945dd7f4bd67a3fce.tar.xz
drakx-backup-do-not-use-9becc48da70169c2a45f09f945dd7f4bd67a3fce.zip
add --error option in order to provide a backtrace
Diffstat (limited to 'perl-install/standalone/drakbug')
-rwxr-xr-xperl-install/standalone/drakbug16
1 files changed, 14 insertions, 2 deletions
diff --git a/perl-install/standalone/drakbug b/perl-install/standalone/drakbug
index 82044336c..d2d3fd2a9 100755
--- a/perl-install/standalone/drakbug
+++ b/perl-install/standalone/drakbug
@@ -27,15 +27,17 @@ use common;
use mygtk2 qw(gtknew);
use ugtk2 qw(:all);
use Config;
+use URI::Escape;
my $prog;
my $incident = 0;
-my ($table, $comb_app, $com_app, $button_pkg, $package, $distrocode);
+my ($table, $comb_app, $com_app, $button_pkg, $package, $distrocode, $error);
my $i;
foreach (@ARGV) {
next unless defined $_;
$i++;
+ /^--error$/ and do { $error = splice(@ARGV, $i, 1) };
/^--report$/ and $prog = splice(@ARGV, $i, 1);
/^--incident$/ and do { $incident = 1; $prog = splice(@ARGV, $i, 1) };
}
@@ -111,7 +113,17 @@ gtkadd($window->{window},
'cf_rpmpkg=' . join('-', $product, $version) : ()),
'component=Core%20Packages',
'classification=Mandriva%20Linux',
- if_($prog, "short_desc=$prog%20crashed"),
+ if_($prog,
+ "short_desc=$prog%20crashed",
+ 'comment=' . uri_escape(qq(The "$prog" program crashed.
+
+Please describe what you were doing when it crashed.
+
+) . ($error ? qq(Backtrace was:
+$error) :
+qq(If you can, try to run the "$prog" program from a terminal and copy and paste here any error messages and/or backtrace)),
+ ),
+ ),
);
print($bugzilla_url . "?" . $options . "\n");
require run_program;