I think exec effectively exits your perl script, you might try system, do, backticks or
Use the imagemagic module to do all of this for you.
perldoc -f exec
perldoc -f system
Dan
>
>
> Hi friends
> I am doing exec in a foreach loop, resizing images.
> But as the the exec is kicked off, it never returns....
> What's the way out?
> Here's the snippet
> -------------------------------------------------------------------
> foreach(@$ref) {
>
> $imgFile = @$_->[1].jpg;
> $thbFile = @$_->[1]-t.jpg;
> $convertedSize = @$_->[3]."x".@$_->[4];
>
> exec("convert $imgFile -resize $convertedSize $thbFile");
>
> }
> ----------------------------------------------------------------------
>
> The loop executes only once, as the exec forks out and waits
> infinitely Help appriciated. Thanks Aman Raheja AGF Inc.
>
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]