Subject: | Undefined return code in _set_status |
Date: | Fri, 12 Sep 2008 08:37:30 +0200 |
To: | bug-CGI-Session [...] rt.cpan.org |
From: | Mario Domgoergen <dom [...] math.uni-bonn.de> |
Hello,
following your code example in the documentation, i used
$session->delete() or warn "couldn't remove " . $session->id . ": " . $session->errstr;
with CGI::Session->find to purge my session entries. But delete() throws
a lot of warnings although the entries were removed from my database.
As _set_status, which is called by delete(), does not return with an
explicit expression, the return code is determined by the for-loop. But
perlsub states:
<If the last statement is a loop control structure like a "foreach" or a
"while", the returned value is unspecified.">
As you can use the bit fiddling in the call to _set_status, i don't see
really a need for the for-loop. Otherwise i would simple remove the warn
statement from the documentation.
CGI-Session-4.34
perl, v5.8.8 built for i486-linux-gnu-thread-multi
Best regards,
Mario
--
Mario Domgoergen - Systemadministration
Mathematische Institut der Universitaet Bonn
Beringstrasse 4, 53115 Bonn / Zimmer 3
Tel.: +49-228-737773 / dom@math.uni-bonn.de