#!/usr/local/bin/perl -w use strict; sub executeStream($); $SIG{CHLD} = 'IGNORE'; # The glob below will work but the message detailed in my original post will occur. my @fileList = glob("/mypath/*.log"); foreach my $logfile (@fileList) { print "Got logfile $logfile\n"; } executeStream(1); sub executeStream($) { my $childProcess; unless (defined($childProcess = fork())) { die "Could not fork new child process."; } unless($childProcess) { # Child process so lets exec the loader. exec("myprog " . $_[0]) or die "Could not exec FeedLoader.pl"; } }