projects
/
awesomized
/
libmemcached
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
|
github
raw
|
patch
| inline |
side by side
(parent:
7947985
)
fix minor bug in compare_servers()
author
Mark Atwood
<mark@fallenpegasus.com>
Sun, 20 Apr 2008 20:17:05 +0000
(13:17 -0700)
committer
Mark Atwood
<mark@fallenpegasus.com>
Sun, 20 Apr 2008 20:17:05 +0000
(13:17 -0700)
libmemcached/memcached_hosts.c
patch
|
blob
|
history
diff --git
a/libmemcached/memcached_hosts.c
b/libmemcached/memcached_hosts.c
index 76fd5a014430ef5cd84291746dfab33d10e75bd9..bdbdcbb684898eaeb130994e44f037c48bb79c23 100644
(file)
--- a/
libmemcached/memcached_hosts.c
+++ b/
libmemcached/memcached_hosts.c
@@
-40,10
+40,7
@@
static int compare_servers(const void *p1, const void *p2)
if (return_value == 0)
{
- if (a->port > b->port)
- return_value++;
- else
- return_value--;
+ return_value= (int) (a->port - b->port);
}
return return_value;