Subject: | $! gets lost when croaking |
Date: | Thu, 23 Feb 2012 11:01:43 +0000 |
To: | bug-Digest-SHA [...] rt.cpan.org |
From: | Zefram <zefram [...] fysh.org> |
When Digest::SHA croaks due to an I/O error, it helpfully tries to include
$! in the error message. However, it does a "require Carp" before looking
at $!, and if Carp wasn't already loaded then this will perform file I/O
that overwrites $!. This leads to getting an incorrect error message.
Attached patch fixes.
-zefram
Message body is not shown because sender requested not to inline it.