From 25dea62ac0410f129840a752544040abd7182953 Mon Sep 17 00:00:00 2001 From: Arne Fitzenreiter Date: Fri, 29 Jan 2010 00:09:33 +0100 Subject: [PATCH] Add delay to pakfire.cgi to prevent pakfire run's twice. --- html/cgi-bin/pakfire.cgi | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/html/cgi-bin/pakfire.cgi b/html/cgi-bin/pakfire.cgi index 8f20d57767..ca7a4ad4d9 100644 --- a/html/cgi-bin/pakfire.cgi +++ b/html/cgi-bin/pakfire.cgi @@ -62,6 +62,7 @@ if ($pakfiresettings{'ACTION'} eq 'install'){ if ("$pakfiresettings{'FORCE'}" eq "on") { my $command = "/usr/local/bin/pakfire install --non-interactive --no-colors $pakfiresettings{'INSPAKS'} &>/dev/null &"; system("$command"); + system("/bin/sleep 1"); } else { &Header::openbox("100%", "center", "Abfrage"); my @output = `/usr/local/bin/pakfire resolvedeps --no-colors $pakfiresettings{'INSPAKS'}`; @@ -101,6 +102,7 @@ END if ("$pakfiresettings{'FORCE'}" eq "on") { my $command = "/usr/local/bin/pakfire remove --non-interactive --no-colors $pakfiresettings{'DELPAKS'} &>/dev/null &"; system("$command"); + system("/bin/sleep 1"); } else { &Header::openbox("100%", "center", "Abfrage"); my @output = `/usr/local/bin/pakfire resolvedeps --no-colors $pakfiresettings{'DELPAKS'}`; @@ -138,10 +140,11 @@ END } elsif ($pakfiresettings{'ACTION'} eq 'update') { system("/usr/local/bin/pakfire update --force --no-colors &>/dev/null &"); - + system("/bin/sleep 1"); } elsif ($pakfiresettings{'ACTION'} eq 'upgrade') { my $command = "/usr/local/bin/pakfire upgrade -y --no-colors &>/dev/null &"; system("$command"); + system("/bin/sleep 1"); } elsif ($pakfiresettings{'ACTION'} eq "$Lang::tr{'save'}") { if ($pakfiresettings{'AUTOUPDATE'} eq 'on') { -- 2.39.2