Francois Gouget : testbot/web: Remove pointless 'cleanup' Submit.pl code.

Alexandre Julliard julliard at winehq.org
Thu May 31 14:31:28 CDT 2018


Module: tools
Branch: master
Commit: bad586dd56194fd577fb5426a5d5c0273b7b614f
URL:    https://source.winehq.org/git/tools.git/?a=commit;h=bad586dd56194fd577fb5426a5d5c0273b7b614f

Author: Francois Gouget <fgouget at codeweavers.com>
Date:   Thu May 31 11:00:20 2018 +0200

testbot/web: Remove pointless 'cleanup' Submit.pl code.

Objects are freed when they get out of scope. So there is no point
setting $Jobs to undef.

Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 testbot/web/Submit.pl | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/testbot/web/Submit.pl b/testbot/web/Submit.pl
index 6451745..3c62c7f 100644
--- a/testbot/web/Submit.pl
+++ b/testbot/web/Submit.pl
@@ -873,21 +873,17 @@ sub OnSubmit($)
     return !1;
   }
 
-  # Clean up, but save the key of the new job
-  my $JobKey = $NewJob->GetKey();
-  $Jobs = undef;
-
   # Notify engine
   my $ErrMessage = RescheduleJobs();
   if (defined $ErrMessage)
   {
     $self->{ErrMessage} = $ErrMessage;
     $self->{Page} = 4;
-    $self->{JobKey} = $JobKey;
+    $self->{JobKey} = $NewJob->GetKey();
     return !1;
   }
 
-  $self->Redirect("/JobDetails.pl?Key=$JobKey"); # does not return
+  $self->Redirect("/JobDetails.pl?Key=". $NewJob->GetKey()); # does not return
   exit;
 }
 




More information about the wine-cvs mailing list