projects
/
platform
/
upstream
/
bash.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
8f4d18e5f8ab626dc10d447b9343d66b4d05f77f
[platform/upstream/bash.git]
/
CWRU
/
misc
/
open-files.c
1
#include <sys/types.h>
2
#include <fcntl.h>
3
#include <sys/file.h>
4
#include <stdio.h>
5
6
main()
7
{
8
register int i;
9
10
for (i = 0; i < getdtablesize(); i++) {
11
if (fcntl(i, F_GETFD, 0) != -1)
12
fprintf(stderr, "fd %d: open\n", i);
13
}
14
exit(0);
15
}
16