'\" -*- coding: UTF-8 -*- .if \n(.g .ds T< \\FC .if \n(.g .ds T> \\F[\n[.fam]] .de URL \\$2 \(la\\$1\(ra\\$3 .. .if \n(.g .mso www.tmac .TH sg_lock_mutex 3 2019-03-08 libstatgrab "" .SH NAME sg_lock_mutex, sg_unlock_mutex \- guard not MT-safe system API .SH SYNOPSIS 'nh .nf \*(T<#include \*(T> .fi .sp 1 .PP .fi .ad l \*(T \kx .if (\nx>(\n(.l/2)) .nr x (\n(.l/5) 'in \n(.iu+\nxu \*(T<(char const *\fImutex_name\fR);\*(T> 'in \n(.iu-\nxu .ad b .PP .fi .ad l \*(T \kx .if (\nx>(\n(.l/2)) .nr x (\n(.l/5) 'in \n(.iu+\nxu \*(T<(char const *\fImutex_name\fR);\*(T> 'in \n(.iu-\nxu .ad b 'hy .SH DESCRIPTION .SH "RETURN VALUES" Both functions return a statgrab error code. \fBerror code\fR: SG_ERROR_NONE .br \fBdescription\fR: No error .PP \fBerror code\fR: SG_ERROR_INVALID_ARGUMENT .br \fBdescription\fR: Unknown name for mutex .PP \fBerror code\fR: SG_ERROR_MUTEX_LOCK .br \fBdescription\fR: thread library error, error code is set with the delivered value .PP \fBerror code\fR: SG_ERROR_MUTEX_UNLOCK .br \fBdescription\fR: thread library error, error code is set with the delivered value .SH "SEE ALSO" \fBstatgrab\fR(3) .SH WEBSITE \(lahttps://libstatgrab.org/\(ra