X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=memcached%2Fthread.c;h=f4bbe1e78d4e5ed8ff90ca80933239adc7e9fbc6;hb=acdfe4229a70c323e66c37e2768dfdea42694bb1;hp=e362249733d47674f39b683898a85da0c880bf38;hpb=81204a653b40f87ae9f43fd8ee12cc8177021f3a;p=m6w6%2Flibmemcached diff --git a/memcached/thread.c b/memcached/thread.c index e3622497..f4bbe1e7 100644 --- a/memcached/thread.c +++ b/memcached/thread.c @@ -88,7 +88,7 @@ unsigned short refcount_incr(unsigned short *refcount) { mutex_lock(&atomics_mutex); (*refcount)++; res = *refcount; - pthread_mutex_unlock(&atomics_mutex); + mutex_unlock(&atomics_mutex); return res; #endif } @@ -103,7 +103,7 @@ unsigned short refcount_decr(unsigned short *refcount) { mutex_lock(&atomics_mutex); (*refcount)--; res = *refcount; - pthread_mutex_unlock(&atomics_mutex); + mutex_unlock(&atomics_mutex); return res; #endif } @@ -113,7 +113,7 @@ void item_lock(uint32_t hv) { } void item_unlock(uint32_t hv) { - pthread_mutex_unlock(&item_locks[hv & item_lock_mask]); + mutex_unlock(&item_locks[hv & item_lock_mask]); } /* @@ -299,9 +299,6 @@ static void *worker_libevent(void *arg) { } -#ifndef __INTEL_COMPILER -#pragma GCC diagnostic ignored "-Wunused-parameter" -#endif /* * Processes an incoming "handle a new connection" item. This is called when * input arrives on the libevent wakeup pipe. @@ -508,7 +505,7 @@ enum store_item_type store_item(item *item, int comm, conn* c) { void item_flush_expired() { mutex_lock(&cache_lock); do_item_flush_expired(); - pthread_mutex_unlock(&cache_lock); + mutex_unlock(&cache_lock); } /* @@ -519,7 +516,7 @@ char *item_cachedump(unsigned int slabs_clsid, unsigned int limit, unsigned int mutex_lock(&cache_lock); ret = do_item_cachedump(slabs_clsid, limit, bytes); - pthread_mutex_unlock(&cache_lock); + mutex_unlock(&cache_lock); return ret; } @@ -529,7 +526,7 @@ char *item_cachedump(unsigned int slabs_clsid, unsigned int limit, unsigned int void item_stats(ADD_STAT add_stats, void *c) { mutex_lock(&cache_lock); do_item_stats(add_stats, c); - pthread_mutex_unlock(&cache_lock); + mutex_unlock(&cache_lock); } /* @@ -538,7 +535,7 @@ void item_stats(ADD_STAT add_stats, void *c) { void item_stats_sizes(ADD_STAT add_stats, void *c) { mutex_lock(&cache_lock); do_item_stats_sizes(add_stats, c); - pthread_mutex_unlock(&cache_lock); + mutex_unlock(&cache_lock); } /******************************* GLOBAL STATS ******************************/ @@ -658,9 +655,6 @@ void slab_stats_aggregate(struct thread_stats *stats, struct slab_stats *out) { } } -#ifndef __INTEL_COMPILER -#pragma GCC diagnostic ignored "-Wsign-compare" -#endif /* * Initializes the thread subsystem, creating various worker threads. *