Skip Menu |
 

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the CGI CPAN distribution.

Report information
The Basics
Id: 33870
Status: resolved
Priority: 0/
Queue: CGI

People
Owner: MARKSTOS [...] cpan.org
Requestors: jstruebig [...] web.de
Cc:
AdminCc:

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



Subject: CGI.pm has probs creating temp file
Date: Fri, 07 Mar 2008 09:24:13 +0100
To: bug-CGI.pm [...] rt.cpan.org
From: Struppi <jstruebig [...] web.de>
Download (untitled) / with headers
text/plain 457b
My Internethoster changed some security issues, so I don't have any permissions to access to the directoy /var/tmp but it still exists. CGI.pm now dies because it want access to this directory. The Problem is at line 4008 (Version 3.33) foreach (@TEMP) { do {$TMPDIRECTORY = $_; last} if -d $_ && -w _; } } The test -d is not enough, I must add && chdir $_ then it works. sorry, I hope you understand my english. regards J. Strübig.
Download (untitled) / with headers
text/plain 1.1k
On Fri Mar 07 03:24:23 2008, jstruebig@web.de wrote: Show quoted text
> My Internethoster changed some security issues, so I don't have any > permissions > to access to the directoy /var/tmp but it still exists. CGI.pm now > dies because > it want access to this directory. > > The Problem is at line 4008 (Version 3.33) > > foreach (@TEMP) { > do {$TMPDIRECTORY = $_; last} if -d $_ && -w _; > } > } > > The test -d is not enough, I must add && chdir $_ then it works.
Thanks for the report. I appreciate the situation, but I don't understand the fix. It looks to me like the logic finds the first entry in @TEMP that is a directory and is also writable. That seems to me like it would be sufficient. I don't understand what the "chdir" is adding. However, I do know that adding a "chdir" could throw off someones code somewhere else if they aren't expecting the directory to change. If a fix like this is really necessary, we should reset the current working directory back to it's previous value. To provide further with addressing this issue, we'll need an automated test to demonstrate it, or specific instructions on how to reproduce the bug.
Download (untitled) / with headers
text/plain 153b
No further follow-up since 2009. Resolving. To re-open, please include a Test::More style test case which reproduces the problem with a failing test.


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.