Skip Menu |

This queue is for tickets about the Digest-SHA CPAN distribution.

Report information
The Basics
Id: 43039
Status: rejected
Worked: 5 min
Priority: 0/
Queue: Digest-SHA

People
Owner: Nobody in particular
Requestors: wjhns117 [...] hardakers.net
Cc:
AdminCc:

Bug Information
Severity: Unimportant
Broken in: 5.47
Fixed in: (no value)



Subject: files with leading spaces can't be checksumed.
I was the maintainer of the fedora package for this module for a while (before it got included in the base perl package) and got this bug report: https://bugzilla.redhat.com/show_bug.cgi?id=478939 Which to summarize quickly is a problem with this line: 120: open(FH, "< $file\0") or _bail("Open failed"); when $file is pointing to a file that contains a leading space (which open will eat). The easy fix would be to use open(FH, "<", $file); instead.
This was fixed in 5.46. Refer to the following for details: http://rt.cpan.org/Public/Bug/Display.html?id=34690 To resolve the problem, note that I did NOT use the 3-arg version of "open", since it's not portable to earlier Perls (< 5.006). Instead, the technique outlined in "perldoc -f open" is employed. Mark