Bug 4150 - do not use break in Perl, use last
: do not use break in Perl, use last
Status: RESOLVED FIXED
: GRAM
gt2 Gatekeeper/Jobmanager
: development
: PC All
: P3 normal
: 4.2
Assigned To:
:
:
:
:
  Show dependency treegraph
 
Reported: 2006-01-10 15:47 by
Modified: 2006-06-27 16:39 (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2006-01-10 15:47:14
You may want to sanity check Perl modules in the CVS for the job manager:

# perl -I$GLOBUS_LOCATION/lib/perl -w -c condor.pm

Unquoted string "break" may clash with future reserved word at condor.pm line 51.
Useless use of a constant in void context at condor.pm line 51.
// should probably be written as "" at condor.pm line 327.
Name "Globus::GRAM::JobManager::condor::Config" used only once: possible typo at
condor.pm line 166.
Name "Globus::GRAM::JobManager::condor::library_string" used only once: possible
typo at condor.pm line 180.
condor.pm syntax OK

[1] don't use "break" in Perl, use "last". The loop will not prematurely exit,
as Perl will ignore the unknown bare word. It does not look harmful, but then, I
didn't write the loop.  

[2] You may want to check out substr( $^O, 0, 4 ) eq 'irix' instead of "use
Config", if all you do is checking if the OS is irix.

[3] library_string is suspicous - where is it declared or initialized. Perl may
use the empty string or undef every time here.
------- Comment #1 From 2006-06-07 14:16:18 -------
Committed fixes to this to CVS trunk.

joe