1 .\" %%%LICENSE_START(PUBLIC_DOMAIN)
2 .\" This page is in the public domain. - aeb
5 .TH UNLOCKPT 3 2021-03-22 "" "Linux Programmer's Manual"
7 unlockpt \- unlock a pseudoterminal master/slave pair
10 .B #define _XOPEN_SOURCE
11 .B #include <stdlib.h>
13 .BI "int unlockpt(int " fd ");"
17 Feature Test Macro Requirements for glibc (see
18 .BR feature_test_macros (7)):
25 .\" || (_XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED)
26 Glibc 2.23 and earlier:
32 function unlocks the slave pseudoterminal device
33 corresponding to the master pseudoterminal referred to by the file descriptor
37 should be called before opening the slave side of a pseudoterminal.
42 Otherwise, it returns \-1 and sets
44 to indicate the error.
50 argument is not a file descriptor open for writing.
55 argument is not associated with a master pseudoterminal.
58 is provided in glibc since version 2.1.
60 For an explanation of the terms used in this section, see
68 Interface Attribute Value
71 T} Thread safety MT-Safe
77 POSIX.1-2001, POSIX.1-2008.