Qp2dlsym()--Find an Exported IBM PASE for i Symbol


  Syntax
 #include <qp2user.h>

 void* Qp2dlsym(QP2_ptr64_t  id
                const char   *name,
                int          ccsid,
                QP2_ptr64_t  *sym_pase);  

  Service Program Name: QP2USER

  Default Public Authority: *USE

  Threadsafe: Yes

Qp2dlsym() finds an exported IBM® i PASE symbol by calling the IBM PASE for i dlsym() function.


Parameters

id
(Input) Specifies a value returned by API Qp2dlopen (or the IBM PASE for i dlopen function) that controls what modules are searched for the exported symbol.

name
(Input) A pointer to a null-terminated string that contains the symbol name. This API copies the input name string and converts the copy from the CCSID specified by the ccsid argument to the current IBM PASE for i CCSID (required by the IBM PASE for i dlsym function).

ccsid
(Input) Specifies the CCSID for the input name argument string. Zero means the symbol name is in the (EBCDIC) job default CCSID.

sym_pase
(Input) A pointer to a buffer, used to return the IBM PASE for i address of the exported symbol. The return value is always 64-bits, even for a 32-bit IBM PASE for i program. sym_pase can be null if the caller does not need the IBM PASE for i address of the symbol.

Authorities

None.


Return Value

The function result is a pointer to the specified symbol, or a null pointer if the symbol could not be resolved. A buffer addressed by the sym_pase argument is unchanged if the symbol could not be resolved. The caller can check ILE errno or IBM PASE for i errno (if ILE errno is zero), or call the Qp2dlerror API for more information about any error.


Related Information



API introduced: V5R2

[ Back to top | IBM PASE for i APIs | APIs by category ]