Problem: Program couldnt make connection to the mail server.
Solution: changed USESSL=>0 to USESSL=>true
Explanation:
If you pass a true value for USESSL, the port will be changed to 995 if it is not set or is 110. Otherwise, it will use your port. If USESSL is true, IO::Socket::SSL will be loaded. If it is not in your perl, the call to connect will fail.
new returns a valid Mail::POP3Client object in all cases. To test for a connection failure, you will need to check the number of messages: -1 indicates a connection error. This will likely change sometime in the future to return undef on an error, setting $! as a side effect. This change will not happen in any 2.x version.
Source : http://search.cpan.org/~sdowd/Mail-POP3Client-2.16/POP3Client.pm
Solution: changed USESSL=>0 to USESSL=>true
Explanation:
If you pass a true value for USESSL, the port will be changed to 995 if it is not set or is 110. Otherwise, it will use your port. If USESSL is true, IO::Socket::SSL will be loaded. If it is not in your perl, the call to connect will fail.
new returns a valid Mail::POP3Client object in all cases. To test for a connection failure, you will need to check the number of messages: -1 indicates a connection error. This will likely change sometime in the future to return undef on an error, setting $! as a side effect. This change will not happen in any 2.x version.
Source : http://search.cpan.org/~sdowd/Mail-POP3Client-2.16/POP3Client.pm
Comments