RE: [Arsperl-users] Problem with ars_GetListContainer
Brought to you by:
jeffmurphy
|
From: Stapff, T. <thi...@ma...> - 2006-02-20 09:50:30
|
Peter,
the problem here seems to be the "|| die ..." operation. From the
"perlop"-manpage:
The "||" and "&&" operators return the last value evaluated
It should work as intended if you try it this way:
my @what = ars_GetListContainer($ctrl, 0,
&ARS::AR_HIDDEN_INCREMENT,
&ARS::ARCON_GUIDE,
&ARS::ARCON_APP,
);
die "ars_GetListContainer error: $ars_errstr\n" if ! @what;
print join(' | ',@what), "\n"; # _DEBUG_
Regards,
Thilo Stapff
-----Original Message-----
From: ars...@ar...
[mailto:ars...@ar...]
Sent: Monday, February 20, 2006 10:23 AM
To: 'ars...@ar...'
Subject: RE: [Arsperl-users] Problem with ars_GetListContainer
> If you are expecting an array result, then surely you want:
>
> my @what = ars_GetListContainer($c->ctrl ...
>
> rather than
>
> my $what
Thanks Richard and Ian for your replies. I should have said in my original
email that my code started with the example that used @l. In this case I
appear to get a single element which is a reference to a hash. However hard
I look at it, my conclusion is always that I just get back a single hash
describing a single container.
Unfortunately I don't have the ability to recompile the module otherwise I
would have put debugging in the code to see what was actually being returned
by the underlying C call.
Regards,
Petet
---
Peter Tyrrell
Relston Consulting Limited
************************************************************************
The information contained in this message or any of its attachments may be
confidential and is intended for the exclusive use of the addressee(s). Any
disclosure, reproduction, distribution or other dissemination or use of this
communication is strictly prohibited without the express permission of the
sender. The views expressed in this email are those of the individual and
not necessarily those of Sony or Sony affiliated companies. Sony email is
for business use only.
This email and any response may be monitored by Sony to be in compliance
with Sony's global policies and standards
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
Arsperl-users mailing list
Ars...@ar...
https://lists.sourceforge.net/lists/listinfo/arsperl-users
|