Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re^13: Help with Lorcon XS library

by syphilis (Archbishop)
on Jul 22, 2020 at 09:25 UTC ( [id://11119628]=note: print w/replies, xml ) Need Help??


in reply to Re^12: Help with Lorcon XS library
in thread Help with Lorcon XS library

I wasn't expecting an example script provided in the Net-Lorcon2-2.03 distribution to fail.
Question 1: What version of perl are you running ? (The output of perl -v probably tells us enough.)
Question 2: Have you installed version 2.03 of Net::Lorcon2 ? If not, please install version 2.03.
Question 3: Have you altered any of the code in any of the Net::Lorcon2 files ? If so, please revert your changes and install Net-Lorcon-2.03 again.

Otherwise, it's a bug in Net::Lorcon2 or Class::Gomor::Array and we will probably need Gomor (or someone else) to sort it out for us.

I think you're right to be suspicious of the _context method.
"_context" starts off as a string in Net::Lorcon2, but apparently gets transformed by the involvement of Class::Gomor::Array into a method. I haven't looked at how that process might be working (or malfunctioning).
I fear that I wouldn't understand it even if I did look.

Cheers,
Rob

Replies are listed 'Best First'.
Re^14: Help with Lorcon XS library
by Bpl (Scribe) on Jul 22, 2020 at 09:40 UTC
    Hi 1) the perl version is 5.22.1 2)yes, it is the 2.03 3)no, I reinstalled it almost 15 times and nothing, still errors. probably is the _context, maybe I'll ask this to Gomor but I think He'll be too busy for reply, is quite sad because the library was almost done :( Thanks again Edoardo M
      I'll ask this to Gomor

      Point out to him that examples/inject.pl is crashing.
      That is a bug in Net::Lorcon2, and might just be enough to get him involved in fixing the problem.
      Let us know if he still refuses to do anything about it ... I could probably try harder if needed ;-)

      Presumably you've built the liborcon2 library from source. Could you provide the link to that source.

      Cheers,
      Rob
        the library is from github: https://github.com/kismetwireless/lorcon Regards Edoardo M. p.s I think that I'll spent more and more time developing it :(
        Hi friend, after some hours of works I think I've finally understood the problem, in few words in the source code
        our @AS = qw( driver interface _drv _context ); __PACKAGE__->cgBuildAccessorsScalar(\@AS); __PACKAGE__->cgBuildIndices; sub new { my $self = shift->SUPER::new( driver => "madwifing", interface => "wlo1", @_, );
        the @_ (under the "new" ) assign a value to $self->_drv and $self->_context, this explain the "undef" obtained in the previous posts, the output of this small program confirm it:
        udo perl -e ' use Net::Lorcon2 qw( :subs ); my $lorcon = Net::Lorcon2->new(); use Data::Dumper; print Dumper($lorcon); '
        outputs
        $VAR1 = bless( [ 'madwifing', 'wlo1', \152948280, \152839568 ], 'Net::Lorcon2' );
        including the $lorcon variable into the  Net::Lorcon2::lorcon_open_inject( $lorcon ) still crash but I think that the problem now stands in the BLESS reference, some hints? Regards Edoardo M

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (3)
As of 2024-03-29 06:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found