mach_port_set_mscount


Function - Change the target port's make-send count.

SYNOPSIS

kern_return_t   mach_port_set_mscount
                (ipc_space_t                               task,
                 mach_port_name_t                          name,
                 mach_port_mscount_t                    mscount);

PARAMETERS

task
[in task send right] The task owning the receive right.

name
[in scalar] task's name for the receive right.

mscount
[in scalar] New value for the make-send count for the receive right.

DESCRIPTION

The mach_port_set_mscount function changes the make-send count of task's receive right named name. A port's make-send count specifies the number of send rights that have been generated via the port's receive right. A port's make-send count is set to zero when the port is first allocated; the count is reset to zero each time the port's receive right is transferred via a Mach message.

NOTES

This interface is machine word length specific because of the port name parameter.

RETURN VALUES

KERN_INVALID_NAME
name did not denote a right.

KERN_INVALID_RIGHT
name denoted a right, but not a receive right.

RELATED INFORMATION

Functions: mach_port_get_attributes.