diff options
-rw-r--r-- | perl-install/standalone/net_applet | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/perl-install/standalone/net_applet b/perl-install/standalone/net_applet index 4ffbd4ab4..a49c75941 100644 --- a/perl-install/standalone/net_applet +++ b/perl-install/standalone/net_applet @@ -15,12 +15,9 @@ my ($menu, $timeout); my $raisedwindow = 0; my $onstartupfile = "$ENV{HOME}/.net_applet"; add_icon_path("/usr/share/libDrakX/pixmaps/"); -#don't launch it twice :) -#my @pids = fuzzy_pidofs(qr/\bnet_applet\b/); -#foreach (@pids) { -# print "pid = $_ \n"; -#} -#@pids > 1 and die "net_applet already running\n"; +# Allow multiple instances, but only one per user: +my @pids = `ps -u $ENV{USER} | grep net_applet`; +@pids > 1 and die "net_applet already running\n"; my $prog_name = "/usr/bin/net_applet"; my $current_md5 = md5file($prog_name); |