Home

Traffic Server Software Developers Kit

INKVIOMutexGet

Returns the mutex for the specified IO operation.

Prototype

INKMutex INKVIOMutexGet (INKVIO viop)

Description

Gets the mutex for the IO operation described by viop. The mutex for the IO operation protects the buffer, continuation, and other VIO members from simultaneous access. The vconnection implementor must obtain the mutex for a VIO before accessing any of its members. Since the VIO mutex is the same as the continuation’s mutex, the vconnection user already holds the mutex whenever he is running and doesn't need to worry about grabbing it. To learn more about why vconnection transformations do not need to grab the VIO mutex before accessing their write VIO, see Transformations.

Returns

The mutex for the specified IO operation.

INK_ERROR_PTR if an error occurs.