diff options
author | Thierry Vignaud <tv@mandriva.org> | 2007-09-26 10:52:34 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mandriva.org> | 2007-09-26 10:52:34 +0000 |
commit | 91c32b5e286c9aef88b6e20d069f0eb13e227bf6 (patch) | |
tree | ec8ed1dec320f53134b67721409f58da7d17099d /perl-install/standalone/drakbug | |
parent | 985e8349ccb4384c2499c900150c7693c6b56e37 (diff) | |
download | drakx-backup-do-not-use-91c32b5e286c9aef88b6e20d069f0eb13e227bf6.tar drakx-backup-do-not-use-91c32b5e286c9aef88b6e20d069f0eb13e227bf6.tar.gz drakx-backup-do-not-use-91c32b5e286c9aef88b6e20d069f0eb13e227bf6.tar.bz2 drakx-backup-do-not-use-91c32b5e286c9aef88b6e20d069f0eb13e227bf6.tar.xz drakx-backup-do-not-use-91c32b5e286c9aef88b6e20d069f0eb13e227bf6.zip |
when unable to access X11, just print the backtrace on the console
Diffstat (limited to 'perl-install/standalone/drakbug')
-rwxr-xr-x | perl-install/standalone/drakbug | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/perl-install/standalone/drakbug b/perl-install/standalone/drakbug index 0e3cb1b5c..210ace916 100755 --- a/perl-install/standalone/drakbug +++ b/perl-install/standalone/drakbug @@ -24,6 +24,7 @@ use lib qw(/usr/lib/libDrakX); use any; use standalone; use common; +BEGIN { $::no_ugtk_init = 1 } use mygtk2 qw(gtknew); use ugtk2 qw(:all); use Config; @@ -42,6 +43,13 @@ foreach (@ARGV) { /^--incident$/ and do { $incident = 1; $prog = splice(@ARGV, $i, 1) }; } +if (!check_for_xserver) { + print("Cannot be run in console mode.\n"); + print N("The \"%s\" program has crashed with the following error:", $prog) . "\n$error\n" if $error; +} + +mygtk2::init(); + $ugtk2::wm_icon = 'drakbug-16'; my $window = ugtk2->new(N("Mandriva Linux Bug Report Tool"), center => 1); $window->{rwindow}->set_border_width(5); |