Skip Menu |

This queue is for tickets about the Statistics-R CPAN distribution.

Report information
The Basics
Id: 70391
Status: resolved
Priority: 0/
Queue: Statistics-R

People
Owner: Nobody in particular
Requestors: florent.angly [...] gmail.com
Cc:
AdminCc:

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



Subject: Portable filenames
I have noticed that Statistics::R does not seem to provide filenames that are cross-platform. At line 58 of Statistics/R/Bridge.pm there is attempts to convert unix-like filenames to Windows: $this->{ START_R } = "$this->{LOG_DIR}/start.r"; ... if ( $this->{ OS } eq 'win32' ) { $this->{ START_R } =~ s/\//\\/g; However, in some other locations, like line 31 or 45, such attempts are not made. The use of the catfile() function of File::Spec (http://perldoc.perl.org/File/Spec.html) would be a much more efficient way of dealing with filenames. For example, the example of line 58 could be replaced simply by: use File::Spec::Functions; $this->{ START_R } = catfile($this->{LOG_DIR}, "start.r"); I am happy to give a hand. Regards, Florent
Fixed in version 0.09