evilkamikaze has asked for the wisdom of the Perl Monks concerning the following question:
I am stuck in a problem and can't figure out what's going on.
What I am doing is this:
I have an array of ports that I need to connect to. For each port in this array I call a function ConnectToPort.
ConnectToPort function creates a socket, and if it successfully connects to the given port (which we have passed as argument) it adds the socket file handle into a text file along with the port number. Now when I read this socket file handle from the file and try to send something on that file handle, I get an error stating that Can't locate object method "send" via package "IO::socket::INET"
I am guessing that it is because when I wrote the socket file handle to a file, it is converted to string. (pardon me if this is really stupid. I am new to perl)
Any help would be greatly appreciated.
Thanks
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Socket Handle not sending data ?
by jbt (Chaplain) on Jul 09, 2009 at 03:36 UTC | |
by evilkamikaze (Initiate) on Jul 09, 2009 at 12:14 UTC | |
by targetsmart (Curate) on Jul 09, 2009 at 13:09 UTC | |
by evilkamikaze (Initiate) on Jul 09, 2009 at 14:19 UTC | |
|
Re: Socket Handle not sending data ?
by targetsmart (Curate) on Jul 09, 2009 at 10:42 UTC | |
by evilkamikaze (Initiate) on Jul 09, 2009 at 14:31 UTC | |
by ikegami (Patriarch) on Jul 09, 2009 at 15:28 UTC | |
by evilkamikaze (Initiate) on Jul 09, 2009 at 19:04 UTC | |
by ikegami (Patriarch) on Jul 09, 2009 at 19:19 UTC | |
|