SPUG: failed: Bad file descriptor
jlb
jlb at io.com
Thu May 12 15:00:13 PDT 2005
Are you sure XMLRPC::Lite sets errno? I would be sort of surprised if it
did. Unless what you're using explicitly states it will set $! in case
of an error, there's a good chance that you're just seeing some irrelevant
leftover error code.
Read the section on $! in perlvar, specifically:
"A successful system or library call does not set the variable to zero."
Which means a call can return success, but there's a good chance $! will
contain an error anyway.
On Thu, 12 May 2005, Luis Medrano wrote:
> List,
>
> I'm running this code below but is showing this error "failed: Bad file descriptor". any Ideas?
>
> Thanks,
> Luis
>
> my $res = XMLRPC::Lite
> -> proxy($proxyurl)
> ## -> call('blogger.getUsersBlogs', $appkey, $username, $password)
> ## -> call('blogger.getRecentPosts', $appkey, $blogid, $username, $password, 4 )
> ## -> call('blogger.newPost', $appkey, $blogid, $username, $password, 4 )
>
> -> call('metaWeblog.newPost', $blogid, $username, $password,
> {
> 'title'=>$title,
> 'description'=>$content,
> 'mt_allow_comments'=>1,
> #'mt_allow_pings'=>1
> },
> 1
> )
> ->result;
>
> if (defined ($res))
> {
> print "--success--\n";
> print Dumper ($res);
> }
> else
> {
> print "failed: $!";
> }
> _____________________________________________________________
> Seattle Perl Users Group Mailing List
> POST TO: spug-list at pm.org
> SUBSCRIPTION: http://mail.pm.org/mailman/listinfo/spug-list
> MEETINGS: 3rd Tuesdays, Location: Amazon.com Pac-Med
> WEB PAGE: http://seattleperl.org/
>
More information about the spug-list
mailing list