[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Perl



> Hello, I tried to execute perl script but with no success. Perl 5.003
> 
> 
> Line number: Text  ............................
> 117:         if (! defined ($ENV{'XXX'})) {
> 118:            print "YYY\n";
> 119:            exit;
> 120:         }
> ............................
> 
> It says:
> 
> syntax error at ./Install line 119, near "exit"
> Execution of ./Install aborted due to compilation errors.
> 
> I tried to write
> 119:    exit 0;
> with no success.
> 

First, This is not a perl group, Use apropriate Usenet group or Perl 
mailing list (go to www.perl.com to find out)

Second, Send me (not to the list ) the whole code, And I'll see into it
I guess that you have a mistake earlier than line 119: and it finds it 
out only at 119
And try the following code

 if (! defined ($ENV{'XXX'})) {
    die "YYY\n";
 }

It'll do the same or
 (defined ($ENV{'XXX'}) || (die "YYY\n";)

Hope this helps to you
-------------------------------------------------------------------------------
Stas Bekman 	sbekman@iil.intel.com.il  [ WebMaster at Intel Corp. ]
Address:	Aba Silver 12/29, Haifa, 32694, Israel
Phones:		[w]  972-(0)4-865-5188, [h]  972-(0)4-828-2264/3020 
Home Page:	http://techunix.technion.ac.il/~ofelix
Resource Center http://www.mardanit.co.il/Center (CGI, PC, Security, Linux)
Linux-il Home:	http://www.linux.org.il/ 	


References: