Commit | Line | Data |
---|---|---|
8adc601b FF |
1 | "The getdtablesize functions has been deprecated by Posix and has been |
2 | removed from Android's LB64 ABI. Replace calls to it with the modern | |
3 | equivalent sysconf(_SC_OPEN_MAX)." | |
4 | ||
5 | - https://groups.google.com/a/chromium.org/forum/#!topic/chromium-reviews/AXhZapYuHi8 | |
6 | ||
7 | diff -u -r ../direvent-5.0/grecs/src/preproc.c ./grecs/src/preproc.c | |
8 | --- ../direvent-5.0/grecs/src/preproc.c 2013-12-17 16:32:57.000000000 -0500 | |
9 | +++ ./grecs/src/preproc.c 2016-01-03 08:46:26.663047361 -0500 | |
10 | @@ -679,7 +679,7 @@ | |
11 | } | |
12 | ||
13 | /* Close unneeded descripitors */ | |
14 | - for (i = getdtablesize(); i > 2; i--) | |
15 | + for (i = sysconf(_SC_OPEN_MAX); i > 2; i--) | |
16 | close(i); | |
17 | ||
18 | if (!grecs_log_to_stderr) { |