summaryrefslogtreecommitdiffstats
path: root/mdkapplet
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2006-04-06 16:49:51 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2006-04-06 16:49:51 +0000
commit9e04e31703a95b2dd65b83b2a428fa53b20152de (patch)
tree79409305827bcae70fe0c51d4a7170887e72ef6a /mdkapplet
parent775f934cab6b4ae6250107c32ac31bc751afde1c (diff)
downloadmgaonline-9e04e31703a95b2dd65b83b2a428fa53b20152de.tar
mgaonline-9e04e31703a95b2dd65b83b2a428fa53b20152de.tar.gz
mgaonline-9e04e31703a95b2dd65b83b2a428fa53b20152de.tar.bz2
mgaonline-9e04e31703a95b2dd65b83b2a428fa53b20152de.tar.xz
mgaonline-9e04e31703a95b2dd65b83b2a428fa53b20152de.zip
add --auto-update option and uses it in restart_applet() so that we
don't fail to rerun ourselves in some obscure conditions
Diffstat (limited to 'mdkapplet')
-rwxr-xr-xmdkapplet8
1 files changed, 5 insertions, 3 deletions
diff --git a/mdkapplet b/mdkapplet
index a1913d9b..58b45d65 100755
--- a/mdkapplet
+++ b/mdkapplet
@@ -38,8 +38,10 @@ use mdkonline;
use Gtk2::TrayIcon;
use Gtk2::NotificationBubble;
-my $pid = mdkonline::is_running('mdkapplet');
-$pid and die "mdkapplet already running ($pid)\n";
+if (!find { $_ eq '--auto-update' } @ARGV) {
+ my $pid = mdkonline::is_running('mdkapplet');
+ $pid and die "mdkapplet already running ($pid)\n";
+}
my $in = interactive->vnew('');
@@ -268,7 +270,7 @@ sub configNetwork() { logIt(N("Launching drakconnect\n")); refresh_gui(0); fork_
sub restart_applet {
logIt(N("Mandriva Online seems to be reinstalled, reloading applet ...."));
- exec($0);
+ exec($0, '--auto-update');
}
sub installUpdates() {