psdanger Subroutine

Purpose

Defines the amount of free paging space available.

Syntax

#include <signal.h>
#include <sys/vminfo.h>

blkcnt_t psdanger (Signal)
int Signal;

Description

The psdanger subroutine returns the difference between the current number of free paging-space blocks and the paging-space thresholds of the system.

Parameters

Item Description
Signal Defines the signal.

Return Values

If the value of the Signal parameter is 0, the return value is the total number of paging-space blocks defined in the system.

If the value of the Signal parameter is -1, the return value is the number of free paging-space blocks available in the system.

If the value of the Signal parameter is SIGDANGER, the return value is the difference between the current number of free paging-space blocks and the paging-space warning threshold. If the number of free paging-space blocks is less than the paging-space warning threshold, the return value is negative.

If the value of the Signal parameter is SIGKILL, the return value is the difference between the current number of free paging-space blocks and the paging-space kill threshold. If the number of free paging-space blocks is less than the paging-space kill threshold, the return value is negative.