[ Bottom of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]

Understanding the Diagnostic Subsystem for AIX

diag_lock

Purpose

Obtain an ODM lock for the specified file

Syntax

#include                <diag/odmi.h>

int diag_lock(char *file)

Description

The diag_lock subroutine calls odm_lock() for a specified file. It waits 5 seconds if a lock cannot be immediately granted.

Parameters

Parameter Description
file Name of the file to lock

Return Value

The diag_lock subroutine returns one of the following values:

Return Code Description
>0 If successful
0 File is already locked
-1 Error

[ Top of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]