From c43e377cff19013c4f40783be35e690ebefb5147 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20A=C3=9Fmus?= Date: Sun, 14 Jun 2009 12:16:18 +0000 Subject: [PATCH] Increase the file handle limit. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31046 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/apps/installer/CopyEngine.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/apps/installer/CopyEngine.cpp b/src/apps/installer/CopyEngine.cpp index 9894ae926b..9537b53551 100644 --- a/src/apps/installer/CopyEngine.cpp +++ b/src/apps/installer/CopyEngine.cpp @@ -10,6 +10,7 @@ #include #include #include +#include #include #include @@ -52,6 +53,12 @@ CopyEngine::CopyEngine(const BMessenger& messenger, BMessage* message) if (fWriterThread >= B_OK) resume_thread(fWriterThread); + + // ask for a bunch more file descriptors so that nested copying works well + struct rlimit rl; + rl.rlim_cur = 512; + rl.rlim_max = RLIM_SAVED_MAX; + setrlimit(RLIMIT_NOFILE, &rl); }