Steve Grazzini wrote:
On Sat, Aug 09, 2003 at 05:14:34PM -0700, Ahmed Moustafa wrote:
Steve Grazzini wrote:
Changes made after the fork() won't be visible in the other process, if that's what you're wondering.
Yes, that's exactly what I am wondering. So, is there a way to assign values to the global variables in the parent process?
No. You'd need to switch to threads or keep the fork and use some kind of IPC.
% perldoc perlipc
Are there threads in Perl?
Yes and no. There are multiple different implementations of threads all of which have some good and bad points. You will need to look more into them depending on your version of Perl and how complex the task is that you wish to accomplish. (There is also a separate mailing list for perl threading).
I have written a similar application using POE, you may want to have a look at it both for doing your process forking (see POE::Wheel::Run) and for your directory scanning.
What is your application doing?
It scans FTP home directories, once it finds a file, it validates the file name, if it is expected or not and then encrypts the file.
http://poe.perl.org
http://danconia.org
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]