fjaenale has asked for the wisdom of the Perl Monks concerning the following question:
$self->{ftp}->put($origin, $target) or $msg = $self->{ftp}->message(), $cod = $self->{ftp}->code(), print ("$cod: $msg\n"), return 1;
-- EDIT: Sorry there is a mistake on the print intruction. I am adding the parenthesis, in the real code it calls a function.--
I just want to know if the way I handle the error is correct. After thte "or" I separate the instructions with ","; I have been told that this is a risky practice. I just want to know if this is really a risky practice or is ok to use the "," as separators.
In case there is a better less risky way, what would be that way?.
Thank you very much,
Francisco Jaen
www.cgi.com
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Error Handling.
by ysth (Canon) on Sep 28, 2004 at 07:25 UTC | |
Re: Error Handling.
by bobf (Monsignor) on Sep 28, 2004 at 07:41 UTC | |
Unless..
by htoug (Deacon) on Sep 28, 2004 at 07:59 UTC |