Code

Merge pull request #408 from radford/curl-json-cache-aliasing
[collectd.git] / src / utils_fbhash.c
index d20b7e39bdd453de1bdec5c4564ed30e994647a6..38b713e7f0d7a8536fb76101bd16bcea5a42bce1 100644 (file)
@@ -234,6 +234,7 @@ void fbh_destroy (fbhash_t *h) /* {{{ */
   if (h == NULL)
     return;
 
+  pthread_mutex_destroy (&h->lock);
   free (h->filename);
   fbh_free_tree (h->tree);
 } /* }}} void fbh_destroy */
@@ -252,7 +253,7 @@ char *fbh_get (fbhash_t *h, const char *key) /* {{{ */
 
   pthread_mutex_lock (&h->lock);
 
-  /* TODO: Checking this everytime may be a bit much..? */
+  /* TODO: Checking this every time may be a bit much..? */
   fbh_check_file (h);
 
   status = c_avl_get (h->tree, key, (void *) &value);