[Previous]
[Contents]
[Next]

sched_getscheduler()

get the current scheduling policy for a process

Synopsis:

#include <sys/sched.h>
int sched_getscheduler( pid_t pid );

Description:

The sched_getscheduler() function gets the current scheduling policy of process pid. If pid is zero, the scheduling policy of the calling process is returned.

Returns:

The scheduling policy. On error, -1 is returned and errno is set.

Errors:

EPERM
The calling process doesn't have sufficient privilege to get the scheduling policy.
ESRCH
The process pid doesn't exist.

Examples:

See qnx_scheduler().

Classification:

POSIX 1003.4

Safety:
Interrupt handler No
Signal handler Yes, but modifies errno
Thread Yes

See also:

errno, getprio(), qnx_scheduler(), sched_getparam(), sched_setparam(), sched_setscheduler(), sched_yield(), setprio()


[Previous]
[Contents]
[Next]