NAME | SYNOPSIS | DESCRIPTION | RETURN VALUES | ERRORS | SEE ALSO
cc [ flag ... ] file ... -ldoor [ library ... ] #include <door.h>int door_info(int d, struct door_info *info);
The door_info() function returns information associated with a door descriptor. door_info() obtains information about the door descriptor d and places the information that is relevant to the door in the structure pointed to by the argument info.
The contents of the info argument contains the following fields:
pid_t di_target; /* door server pid */ door_ptr_t di_proc; /* server function */ door_ptr_t di_data; /* data cookie for invocation */ door_attr_t di_attributes; /* door attributes */ door_id_t di_uniquifier; /* unique id among all doors */
di_target is the process ID of the door server, or -1 if the door server process has exited.
The values for di_attributes may be composed of the following:
The door descriptor refers to a service procedure in this process.
The door has requested notification when all but the last reference has gone away.
The door descriptor refers to a door that has been revoked.
The door has a separate pool of server threads associated with it.
The di_proc and di_data fields are returned as door_ptr_t objects rather than void * pointers in order to allow clients and servers to interoperate in environments where the pointer sizes may vary in size (for example, 32-bit clients and 64-bit servers). Each door has a system-wide unique number associated with it that is set when the door is created by door_create(). This number is returned in di_uniquifier.
Upon successful completion, 0 is returned. Upon failure, -1 is returned and errno is set to indicate the error.
The door_info() function fails if:
The address of argument info is an invalid address.
d is not a door descriptor.
NAME | SYNOPSIS | DESCRIPTION | RETURN VALUES | ERRORS | SEE ALSO