dlopen() crashing

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

dlopen() crashing

Schwab,Wilhelm K
Hello all,

I am trying to use dlsym() which means I have to call dlopen(), and it is crashing with messages such as

     Inconsistency detected by ld.so: dl-open.c: 643: _dl_open:
      Assertion `_dl_debug_initialize (0, args.nsid)->r_state == RT_CONSISTENT' failed!

I am calling it as follows:

dlOpen:aString mode:int
    < cdecl: void* 'dlopen' ( char* long ) >  
    ^ self externalCallFailed.

With zero for the mode parameter, it runs but returns an null handle; with 2 (now) or 10 (now|global), it crashes.

Any ideas or working examples?

Bill


Reply | Threaded
Open this post in threaded view
|

Re: dlopen() crashing

Bert Freudenberg
On 01.04.2010, at 16:53, Schwab,Wilhelm K wrote:

>
> Hello all,
>
> I am trying to use dlsym() which means I have to call dlopen(), and it is crashing with messages such as
>
>     Inconsistency detected by ld.so: dl-open.c: 643: _dl_open:
>      Assertion `_dl_debug_initialize (0, args.nsid)->r_state == RT_CONSISTENT' failed!
>
> I am calling it as follows:
>
> dlOpen:aString mode:int
>    < cdecl: void* 'dlopen' ( char* long ) >  
>    ^ self externalCallFailed.
>
> With zero for the mode parameter, it runs but returns an null handle; with 2 (now) or 10 (now|global), it crashes.

Shouldn't you declare the "mode" parameter?

- Bert -



Reply | Threaded
Open this post in threaded view
|

Re: dlopen() crashing

Schwab,Wilhelm K
In reply to this post by Schwab,Wilhelm K
Bert,

What do you mean by "declare the mode parameter" - did I not do that via the argument named int?

Bill