Pazpar2 1.4.4-2 for squeeze
[pazpar2-moved-to-github.git] / src / normalize_cache.c
index a863fc3..e99f576 100644 (file)
@@ -27,6 +27,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 #include <config.h>
 #endif
 
+#include "ppmutex.h"
 #include "normalize_cache.h"
 
 #include "pazpar2_config.h"
@@ -50,13 +51,12 @@ normalize_cache_t normalize_cache_create(void)
     nc->nmem = nmem;
     nc->items = 0;
     nc->mutex = 0;
-    yaz_mutex_create(&nc->mutex);
-    yaz_mutex_set_name(nc->mutex, "normalize_cache");
+    pazpar2_mutex_create(&nc->mutex, "normalize_cache");
     return nc;
 }
 
 normalize_record_t normalize_cache_get(normalize_cache_t nc,
-                                       struct conf_service *service,
+                                       struct conf_config *conf,
                                        const char *spec)
 {
     normalize_record_t nt;
@@ -70,7 +70,7 @@ normalize_record_t normalize_cache_get(normalize_cache_t nc,
         nt = ci->nt;
     else
     {
-        nt = normalize_record_create(service, spec);
+        nt = normalize_record_create(conf, spec);
         if (nt)
         {
             ci = nmem_malloc(nc->nmem, sizeof(*ci));