install auto unload time event only when we have at least one auto unload module

git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@2509 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
Lennart Poettering 2008-06-11 16:55:26 +00:00
parent 2cc95df859
commit f7ff9e2dd2

View file

@ -120,7 +120,7 @@ pa_module* pa_module_load(pa_core *c, const char *name, const char *argument) {
if (!c->modules)
c->modules = pa_idxset_new(NULL, NULL);
if (!c->module_auto_unload_event) {
if (m->auto_unload && !c->module_auto_unload_event) {
struct timeval ntv;
pa_gettimeofday(&ntv);
pa_timeval_add(&ntv, UNLOAD_POLL_TIME*1000000);