☰
Debian Codegraph
@
0.0~git20260129.ec0effd-3
0.0~git20260129.ec0effd-2
/
/
libc-top-half
/
musl
/
src
/
misc
/
ptsname.c
☽
☼
libc-top-half/musl/src/misc/ptsname.c
code
plain
raw
MIT
2005-2019 Rich Felker <
[email protected]
>; 2005-2019 Many other contributors
debian/copyright
1
#include <stdlib.h>
2
#include <errno.h>
3
4
char *ptsname(int fd)
5
{
6
static char buf[9 + sizeof(int)*3 + 1];
7
int err = __ptsname_r(fd, buf, sizeof buf);
8
if (err) {
9
errno = err;
10
return 0;
11
}
12
return buf;
13
}