Skip to content

Latest commit

 

History

History
44 lines (32 loc) · 1.1 KB

lock.md

File metadata and controls

44 lines (32 loc) · 1.1 KB
description title ms.date api_name api_location api_type topic_type f1_keywords helpviewer_keywords ms.assetid
Learn more about: _lock
_lock
11/04/2016
_lock
msvcr110_clr0400.dll
msvcr120.dll
msvcr100.dll
msvcr90.dll
msvcr80.dll
msvcr110.dll
msvcrt.dll
msvcr120_clr0400.dll
DLLExport
apiref
_lock
lock function
_lock function
29f77c37-30de-4b3d-91b6-030216e645a6

_lock

Acquires a multi-thread lock.

Important

This function is obsolete. Beginning in Visual Studio 2015, it is not available in the CRT.

Syntax

void __cdecl _lock
   int locknum
);

Parameters

locknum
[in] The identifier of the lock to acquire.

Remarks

If the lock has already been acquired, this method acquires the lock anyway and causes an internal C run-time (CRT) error. If the method can't acquire a lock, it exits with a fatal error and sets the error code to _RT_LOCK.

Requirements

Source: mlock.c

See also

Alphabetical function reference
_unlock