'\" te .\" Copyright (c) 1998 Sun Microsystems, Inc. All Rights Reserved .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License. .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner] .TH TD_THR_LOCKOWNER 3C_DB "Oct 20, 1998" .SH NAME td_thr_lockowner \- iterate over the set of locks owned by a thread .SH SYNOPSIS .LP .nf cc [ \fIflag\fR... ] \fIfile\fR... -lc_db [ \fIlibrary\fR... ] #include #include \fBtd_err_e\fR \fBtd_thr_lockowner\fR(\fBconst td_thrhandle_t *\fR\fIth_p\fR, \fBtd_sync_iter_f *\fR\fIcb\fR, \fBvoid *\fR\fIcb_data_p\fR); .fi .SH DESCRIPTION .sp .LP The \fBtd_thr_lockowner()\fR function calls the iterator function \fIcb\fR once for every mutex that is held by the thread whose handle is \fIth_p\fR. The synchronization handle and the pointer \fIcb_data_p\fR are passed to the function. See \fBtd_ta_thr_iter\fR(3C_DB) for a similarly structured function. .sp .LP Iteration terminates early if the callback function \fIcb\fR returns a non-zero value. .SH RETURN VALUES .sp .ne 2 .na \fB\fBTD_OK\fR\fR .ad .RS 12n The call completed successfully. .RE .sp .ne 2 .na \fB\fBTD_BADTH\fR\fR .ad .RS 12n An invalid thread handle was passed in. .RE .sp .ne 2 .na \fB\fBTD_BADPH\fR\fR .ad .RS 12n There is a \fINULL\fR external process handle associated with this internal process handle. .RE .sp .ne 2 .na \fB\fBTD_DBERR\fR\fR .ad .RS 12n A call to one of the imported interface routines failed. .RE .sp .ne 2 .na \fB\fBTD_ERR\fR\fR .ad .RS 12n A \fBlibc_db\fR internal error occurred. .RE .SH ATTRIBUTES .sp .LP See \fBattributes\fR(5) for description of the following attributes: .sp .sp .TS box; c | c l | l . ATTRIBUTE TYPE ATTRIBUTE VALUE _ MT-Level Safe .TE .SH SEE ALSO .sp .LP \fBlibc_db\fR(3LIB), \fBtd_ta_thr_iter\fR(3C_DB), \fBattributes\fR(5)