Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: Re: Hanging program

by Anonymous Monk
on Apr 11, 2003 at 03:05 UTC ( #249793=note: print w/ replies, xml ) Need Help??

in reply to Re: Hanging program
in thread Hanging program

Program dies after "Information is being passed.". Does this help?
#!/usr/bin/perl use strict; use warnings; my $user = "wfgs343R"; my $pass = "iamcool"; my $aim; print "Subject's Name:"; chomp(my $destuser = <STDIN>); print "Message:"; chomp(my $message = <STDIN>); use Net::AOLIM; $aim = Net::AOLIM->new( 'username' => $user, 'password' => $pass, 'callback' => \&callbackfunction, 'server' => '', 'port' => 1234, 'allow_srv_settings' => 1, 'login_server' => '', 'login_port' => 5198, 'login_timeout' => 0, 'aim_agent' => "$Net::AOLIM::VERSION"); print "Information is being passed.\n"; $aim->signon; print "Aim is signed on.\n"; $aim->toc_send_im($destuser, $message); print "Done\n";
Comment on Re: Re: Hanging program
Download Code
Replies are listed 'Best First'.
Re: Re: Re: Hanging program
by krujos (Curate) on Apr 11, 2003 at 03:22 UTC
    You are missing () after $aim->signon I dont know if this makes a difference honestly. You should check the return value of signon, when I ran your code, (with my aim of course) the return value of signon was undef (which the docs say means it failed). According to the documentation there are some error messages you can get back (IM_ERR). Try printing those out.
    Also, it takes about thirty or forty seconds for the signon to fail, are you waiting long enough?
    Good luck,

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://249793]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (10)
As of 2016-05-26 15:46 GMT
Find Nodes?
    Voting Booth?