[pulseaudio-commits] r2530 - /trunk/src/pulsecore/core-scache.c

svnmailer-noreply at 0pointer.de svnmailer-noreply at 0pointer.de
Sat Jun 14 14:33:50 PDT 2008


Author: lennart
Date: Sat Jun 14 23:33:49 2008
New Revision: 2530

URL: http://0pointer.de/cgi-bin/viewcvs.cgi?rev=2530&root=pulseaudio&view=rev
Log:
minor modernizations, increase unload timeout to 60s

Modified:
    trunk/src/pulsecore/core-scache.c

Modified: trunk/src/pulsecore/core-scache.c
URL: http://0pointer.de/cgi-bin/viewcvs.cgi/trunk/src/pulsecore/core-scache.c?rev=2530&root=pulseaudio&r1=2529&r2=2530&view=diff
==============================================================================
--- trunk/src/pulsecore/core-scache.c (original)
+++ trunk/src/pulsecore/core-scache.c Sat Jun 14 23:33:49 2008
@@ -63,7 +63,7 @@
 
 #include "core-scache.h"
 
-#define UNLOAD_POLL_TIME 5
+#define UNLOAD_POLL_TIME 60
 
 static void timeout_callback(pa_mainloop_api *m, pa_time_event*e, PA_GCC_UNUSED const struct timeval *tv, void *userdata) {
     pa_core *c = userdata;
@@ -131,8 +131,7 @@
     }
 
     e->last_used_time = 0;
-    e->memchunk.memblock = NULL;
-    e->memchunk.index = e->memchunk.length = 0;
+    pa_memchunk_reset(&e->memchunk);
     e->filename = NULL;
     e->lazy = FALSE;
     e->last_used_time = 0;
@@ -277,8 +276,7 @@
     if (!(e = pa_namereg_get(c, name, PA_NAMEREG_SAMPLE, 0)))
         return -1;
 
-    if (pa_idxset_remove_by_data(c->scache, e, NULL) != e)
-        pa_assert(0);
+    pa_assert_se(pa_idxset_remove_by_data(c->scache, e, NULL) == e);
 
     pa_log_debug("Removed sample \"%s\"", name);
 




More information about the pulseaudio-commits mailing list