Sign in Join
FPDoc Onlineexperiment

TryEnterCriticalSection function

In unit System

Try entering a critical section.

Declaration

pascal
function TryEnterCriticalSection(var cs: TRTLCriticalSection): LongInt

Description

TryEnterCriticalsection attempts to enter critical section cs. It returns at once. The return value is zero if another thread owns the critical section, or nonzero if the current thread already owns or successfully obtained the critical section.

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.