[ macperl-Bugs-488634 ] @ARGV and droplets
[email protected] Mon, 03 Dec 2001 15:14:14 -0800
| Newsgroups | perl.macperl.porters |
|---|---|
| Message-ID | <[email protected]> |
Bugs item #488634, was opened at 2001-12-03 15:14
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=107940&aid=488634&group_id=7940
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Axel Rose (axelrose)
Assigned to: Nobody/Anonymous (nobody)
Summary: @ARGV and droplets
Initial Comment:
#!perl -w
use strict;
die "no input, no output\n" unless @ARGV;
print "DEBUG: \[0] = $ARGV[0]\n";
my @files;
if( -d $ARGV[0] ) { @files = glob( "$ARGV[0]*" ) }
else { @files = @ARGV }
my $i = 0;
for ( @files ) { print $i++, " '$_'\n" }
In my installation when used as a droplet this yields:
DEBUG: $ARGV[0] = Festplatte:Desktop Folder:perl:Cache-Cache-0.09:lib:Cache Kopie:
0 'Festplatte:Desktop'
1 'Folder:perl:Cache-Cache-0.09:lib:Cache'
done.
It looks like @ARGV is splitted by space.
Everything works fine if the name of the dropped folder does
not contain any spaces.
BTW - I tried in 5.20r4. There I get:
DEBUG: $ARGV[0] = Festplatte:Desktop Folder:perl:Cache-Cache-0.09:lib:Cache Kopie
# Read on closed filehandle <_GEN_0>.
----------------------------------------------------------------------
You can respond by visiting:
http://sourceforge.net/tracker/?func=detail&atid=107940&aid=488634&group_id=7940