From kde-commits Mon Jul 30 17:54:40 2012 From: =?utf-8?q?Lubo=C5=A1=20Lu=C5=88=C3=A1k?= Date: Mon, 30 Jul 2012 17:54:40 +0000 To: kde-commits Subject: icecream/daemon Message-Id: <20120730175440.5FE73AC7A9 () svn ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=134367115301808 SVN commit 1308594 by lunakl: keep native envs longer only if there aren't too many M +3 -1 main.cpp --- trunk/icecream/daemon/main.cpp #1308593:1308594 @@ -870,11 +870,13 @@ // ignore recently used envs (they might be in use _right_ now) int keep_timeout = 200; bool native = false; - // If it is a native environment, allow removing it only after a longer period. + // If it is a native environment, allow removing it only after a longer period, + // unless there are many native environments. for (map::const_iterator it2 = native_environments.begin(); it2 != native_environments.end(); ++it2 ) { if (it2->second.name == it->first) { native = true; + if (native_environments.size() < 5) keep_timeout = 24 * 60 * 60; // 1 day break; }