repo.or.cz
/
trinity.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
remove [64] cleanup TODO
[trinity.git]
/
syscalls
/
dup.c
blob
68278d1c2e17995fa8064be963fdef20be2217f6
1
/*
2
* SYSCALL_DEFINE1(dup, unsigned int, fildes)
3
*
4
* On success, returns the new descriptor.
5
* On error, -1 is returned, and errno is set appropriately.
6
*/
7
#include
"sanitise.h"
8
9
struct
syscallentry syscall_dup
= {
10
.
name
=
"dup"
,
11
.
num_args
=
1
,
12
.
arg1name
=
"fildes"
,
13
.
arg1type
=
ARG_FD
,
14
.
rettype
=
RET_FD
,
15
.
flags
=
NEED_ALARM
,
16
};