Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Unified Diff: tools/android/adb_reboot/adb_reboot.c

Issue 349323003: [Android]: Replace calls to getdtablesize with sysconf(_SC_OPEN_MAX) in tools. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/test/multiprocess_test_android.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/android/adb_reboot/adb_reboot.c
diff --git a/tools/android/adb_reboot/adb_reboot.c b/tools/android/adb_reboot/adb_reboot.c
index 48c5cbe58f251d054aec0ecc087de290c35df829..d414dd5d3583a2c41d9136a0ede88661d700c38e 100644
--- a/tools/android/adb_reboot/adb_reboot.c
+++ b/tools/android/adb_reboot/adb_reboot.c
@@ -23,7 +23,7 @@ int main(int argc, char ** argv) {
/* child (daemon) continues */
int j;
- for (j = 0; j < getdtablesize(); j++)
+ for (j = 0; j < sysconf(_SC_OPEN_MAX); j++)
close(j);
setsid(); /* obtain a new process group */
« no previous file with comments | « base/test/multiprocess_test_android.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698