Skip Menu |
 

This queue is for tickets about the Cache-Cache CPAN distribution.

Report information
The Basics
Id: 13674
Status: resolved
Priority: 0/
Queue: Cache-Cache

People
Owner: Nobody in particular
Requestors: info [...] whawes.co.uk
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 1.04
Fixed in: (no value)

Attachments


MIME-Version: 1.0
X-Mailer: MIME-tools 5.415 (Entity 5.415)
Subject: Bug in Cache::FileBackend 1.27 on Win32
Content-Type: multipart/mixed; boundary="----------=_1121264477-15976-0"
Content-Length: 0
Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: iso-8859-1
Content-Length: 612
Download (untitled) / with headers
text/plain 612b
Cache::FileBackend 1.27 does not pass a drive letter to File::Temp::tempfile(). This is not a problem on a Unix based system, but on a Win32 system causes Cache::FileCache to die: "Error in tempfile() using \temp\FileCache\Default\9\2\4\XXXXXXXXXX: Parent directory (\temp\FileCache\Default\9\2\4\) is not a directory at C:/Perl/site/lib/Cache/FileBackend.pm line 563" The attached patch corrects this behaviour, prepending the directory path with a drive letter if one is present or an empty string if not. I have verified this fix on Windows 2003 with ActivePerl 5.8.7 and Windows 2000 with ActivePerl 5.8.4.
Content-Type: application/octet-stream; name="FileBackend.patch"
Content-Disposition: inline; filename="FileBackend.patch"
Content-Transfer-Encoding: base64
Content-Length: 399
Download FileBackend.patch
text/x-diff 399b
--- FileBackend_orig.pm Wed Jul 13 14:53:41 2005 +++ FileBackend.pm Wed Jul 13 14:55:50 2005 @@ -559,7 +559,8 @@ my ( $volume, $directory, $filename ) = File::Spec->splitpath( $p_path ); - my ( $temp_fh, $temp_filename ) = tempfile( DIR => $directory ); + $volume ||= ''; + my ( $temp_fh, $temp_filename ) = tempfile( DIR => $volume . $directory ); binmode( $temp_fh );
Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: binary
MIME-Version: 1.0
X-Mailer: MIME-tools 5.415 (Entity 5.415)
X-RT-Original-Encoding: iso-8859-1
Content-Length: 309
Download (untitled) / with headers
text/plain 309b
I have a fixed that I'm checking in for the 1.05 release. It is slightly different than the one you suggested, but only insofar as I wanted to be consistent with some other similar code. Feel free to check out the CVS version if it is urgent. And I'd love to hear confirmation if the fix worked. Thanks@
Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: binary
MIME-Version: 1.0
X-Mailer: MIME-tools 5.418 (Entity 5.418)
X-RT-Original-Encoding: iso-8859-1
Content-Length: 437
Download (untitled) / with headers
text/plain 437b
[DCLINTON - Wed Jul 13 18:29:46 2005]: Show quoted text
> I have a fixed that I'm checking in for the 1.05 release. It is > slightly different than the one you suggested, but only insofar as I > wanted to be consistent with some other similar code. > > Feel free to check out the CVS version if it is urgent. And I'd love > to > hear confirmation if the fix worked. Thanks@ >
So is that 1.05 release ever going to be made available out of CVS?
Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: binary
MIME-Version: 1.0
X-Mailer: MIME-tools 5.418 (Entity 5.418)
From: johanl ÄT darserman.com
X-RT-Original-Encoding: iso-8859-1
Content-Length: 145
Download (untitled) / with headers
text/plain 145b
Show quoted text
> So is that 1.05 release ever going to be made available out of CVS?
Yes, please, please, please, make a release with this fix! Please? /J
MIME-Version: 1.0
X-Mailer: MIME-tools 5.418 (Entity 5.418)
Content-Disposition: inline
Message-Id: <rt-3.5.HEAD-20912-1146156565-1341.13674-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf8"
Content-Transfer-Encoding: binary
From: aaronw6 [...] gmail.com
X-RT-Original-Encoding: utf-8
X-RT-Original-Encoding: utf-8
Content-Length: 846
Download (untitled) / with headers
text/plain 846b
On Wed Jul 13 10:21:18 2005, guest wrote: Show quoted text
> Cache::FileBackend 1.27 does not pass a drive letter to > File::Temp::tempfile(). This is not a problem on a Unix based > system, but on a Win32 system causes Cache::FileCache to die: > > "Error in tempfile() using \temp\FileCache\Default\9\2\4\XXXXXXXXXX: > Parent directory (\temp\FileCache\Default\9\2\4\) is not a > directory at C:/Perl/site/lib/Cache/FileBackend.pm line 563" > > The attached patch corrects this behaviour, prepending the directory > path with a drive letter if one is present or an empty string if > not. I have verified this fix on Windows 2003 with ActivePerl
5.8.7 Show quoted text
> and Windows 2000 with ActivePerl 5.8.4.
The above attached fix worked great, When is the fix going to be put in the PM, or at least state that there is a problem for win32 systems.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.