Fix paren style, and mark replication with the unlikely keyword
authorTrond Norbye <trond.norbye@sun.com>
Sun, 14 Jun 2009 11:47:00 +0000 (13:47 +0200)
committerTrond Norbye <trond.norbye@sun.com>
Sun, 14 Jun 2009 11:47:00 +0000 (13:47 +0200)
libmemcached/memcached_delete.c
libmemcached/memcached_get.c
libmemcached/memcached_storage.c

index 5eb7e39c5ddd604750bcde94ac14f5db89c57aae..93b1eb7a1a6f7e95415e20976881b7f598046a29 100644 (file)
@@ -129,7 +129,7 @@ static inline memcached_return binary_delete(memcached_st *ptr,
     rc= MEMCACHED_WRITE_FAILURE;
   }
 
-  if (ptr->number_of_replicas > 0) 
+  unlikely (ptr->number_of_replicas > 0) 
   {
     request.message.header.request.opcode= PROTOCOL_BINARY_CMD_DELETEQ;
 
index cdfb5d29082c56366d253c826d948fa6c969015a..6ab5b2ff54c54257e353b58db226bda9cc26a294 100644 (file)
@@ -465,7 +465,8 @@ static memcached_return binary_mget_by_key(memcached_st *ptr,
 {
   memcached_return rc;
 
-  if (ptr->number_of_replicas == 0) {
+  if (ptr->number_of_replicas == 0) 
+  {
     rc= simple_binary_mget(ptr, master_server_key, is_master_key_set,
                            keys, key_length, number_of_keys);
   } else {
index fe8024d305e0e72bf9b3b9f0c334e2ebe2b8a890..713f831d2c4fe399cfddd8443e4b453a5a2ea5ca 100644 (file)
@@ -470,7 +470,7 @@ static memcached_return memcached_send_binary(memcached_st *ptr,
     return MEMCACHED_WRITE_FAILURE;
   }
 
-  if (verb == SET_OP && ptr->number_of_replicas > 0) 
+  unlikely (verb == SET_OP && ptr->number_of_replicas > 0) 
   {
     request.message.header.request.opcode= PROTOCOL_BINARY_CMD_SETQ;