Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

audit_control(5)

GETACINFO(3)  —  C LIBRARY FUNCTIONS

NAME

getacinfo, getacdir, getacflg, getacmin, setac, endac − get audit control file information

SYNOPSIS

int getacdir(dir, len)
char ∗dir;
int len;

int getacmin(min_val)
int ∗min_val;

int getacflg(auditstring, len)
char ∗auditstring;
int len;

void setac()

void endac()

DESCRIPTION

When first called, getacdir() provides information about the first audit directory in the audit_control file; thereafter, it returns the next directory in the file.  Successive calls list all the directories listed in audit_control(5) The parameter len specifies the length of the buffer dir .  On return, dir points to the directory entry. 

getacmin() reads the minimum value from the audit_control file and returns the value in min_val.  The minimum value specifies how full the file system to which the audit files are being written can get before the script audit_warn is invoked. 

getacflg() reads the system audit value from the audit_control file and returns the value in auditstring.  The parameter len specifies the length of the buffer auditstring. 

Calling setac rewinds the audit_control file to allow repeated searches. 

Calling endac closes the audit_control file when processing is complete. 

RETURN VALUE

Upon successful completion of all getac... functions, a zero is returned. getacmin() and getacflg() return a 1 on EOF.  Only getacdir() returns a 2 if the directory search had to start from the beginning because another getac... function was called between calls to getacdir. 

ERRORS

Upon unsuccessful completion, a value of −2 is returned and errno is set to indicate the error.  −3 is returned if the directory entry format in the.  audit_control file is incorrect.  If the input buffer is too short to accommodate the record, getacdir() and getacflg() return an error code of −3.  Only getacdir() returns a −1 on end of file. 

SEE ALSO

audit_control(5)

Sun Release 4.0  —  Last change: 22 November 1987

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