Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ ldr_xlookup_package(3) — OSF/1 3.0 αXP

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

ldr_xload(3)

ldr_xlookup_package(3)  —  Subroutines

NAME

ldr_xlookup_package − Returns the address of a symbol name within a specified package in another process

LIBRARY

Standard C Library (libc.a)

SYNOPSIS

#include <sys/types.h>
#include <loader.h>
int ldr_xlookup_package(
ldr_process_tprocess,
char ∗package_name,
char ∗symbol_name,
void ∗∗symbol_addr_ptr);

PARAMETERS

processSpecifies the process whose address space contains the package with the symbol whose address is required. 

package_name
Specifies the name of the package that contains the symbol name.

symbol_name
Specifies the name of the symbol whose address is required.

symbol_addr_ptr
Points to a void∗ variable.  The function returns the address for the symbol name in this variable. 

DESCRIPTION

The ldr_xlookup_package() function returns the address of the specified symbol name within the specified package.  The package is contained within the address space of the specified process. 

To obtain the unique identifier for the current process, use the following call:

ldr_process_t ldr_my_process();

To obtain the unique identifier for the kernel, use the following call:

ldr_process_t ldr_kernel_process();

NOTES

This call currently only supports lookup in the current process or the kernel. 

The loader employs a two-dimensional hierarchical symbol name space in which each symbol is represented by a package name, symbol name pair.  Package names are attached to symbols at link time.  The package scheme assumes that each symbol name is unique within its package and that each package name is unique across the system. 

RETURN VALUES

If the operation is a success, the function returns a value of 0 (zero).  If the operation fails, the function returns a negative value and errno is set to indicate the error. 

ERRORS

If the ldr_xlookup_package() function fails, errno may be set to one of the following values:

[ENOPKG]The specified package was not found. 

[ENOSYM]The specified symbol name was not found in the specified package. 

[ESRCH]The process identifier is invalid. 

[ERANGE]The symbol address could not be converted into an absolute value. 

Additional errors may be returned from the underlying IPC mechanism. 

RELATED INFORMATION

Functions: ldr_xload(3)

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026