repo.or.cz
/
musl.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
fix the use of uninitialized value in regcomp
[musl.git]
/
src
/
misc
/
ptsname.c
blob
a34779276fa011be935e1db0860d775165ba8729
1
#include <stdlib.h>
2
#include <errno.h>
3
4
int
__ptsname_r
(
int
,
char
*,
size_t
);
5
6
char
*
ptsname
(
int
fd
)
7
{
8
static char
buf
[
9
+
sizeof
(
int
)*
3
+
1
];
9
int
err
=
__ptsname_r
(
fd
,
buf
,
sizeof
buf
);
10
if
(
err
) {
11
errno
=
err
;
12
return
0
;
13
}
14
return
buf
;
15
}