memcached 0.17.1 → 0.17.2

Sign up to get free protection for your applications and to get access to all the features.
data.tar.gz.sig CHANGED
Binary file
data/CHANGELOG CHANGED
@@ -1,4 +1,6 @@
1
1
 
2
+ v0.17.2. Fix realloc bug on Linux that got regressed.
3
+
2
4
  v0.17.1. Ruby 1.9 compatibility.
3
5
 
4
6
  v0.17. Update to libmemcached 0.32. Update Darwin version string for Snow Leopard final. Improve benchmarks. Add Memcached::Rails#append and #prepend, alias all original Memcached methods to _orig, and add set_servers= accessor for compatibility.
data/README CHANGED
@@ -90,8 +90,6 @@ There is a compatibility wrapper for legacy applications called Memcached::Rails
90
90
  # Perform operations on cache, not $cache
91
91
  cache.set 'example', 1
92
92
  cache.get 'example'
93
- # ...
94
- cache.destroy
95
93
  end
96
94
 
97
95
  # Join the thread so that exceptions don't get lost
@@ -104,7 +104,7 @@ index 129d761..3a7fa55 100644
104
104
  + return memcached_live_host_index(ptr, hash);
105
105
  case MEMCACHED_DISTRIBUTION_RANDOM:
106
106
  - return (uint32_t) random() % ptr->number_of_hosts;
107
- + return memcached_live_host_index(ptr, (int)random());
107
+ + return memcached_live_host_index(ptr, (uint32_t) random());
108
108
  default:
109
109
  WATCHPOINT_ASSERT(0); /* We have added a distribution without extending the logic */
110
110
  return hash % ptr->number_of_hosts;
@@ -170,13 +170,13 @@ diff --git a/libmemcached-0.32/libmemcached/memcached_hosts.c b/libmemcached/lib
170
170
  + }
171
171
  +
172
172
  + if (ptr->live_host_indices == NULL) {
173
- + ptr->live_host_indices = (uint32_t *)ptr->call_malloc(ptr, sizeof(uint32_t) * ptr->number_of_live_hosts);
173
+ + ptr->live_host_indices = (uint32_t *)ptr->call_malloc(ptr, sizeof(uint32_t) * ptr->number_of_hosts);
174
174
  + ptr->live_host_indices_size = ptr->number_of_live_hosts;
175
175
  + }
176
176
  +
177
177
  + /* somehow we added some hosts. Shouldn't get here much, if at all. */
178
178
  + if (ptr->live_host_indices_size < ptr->number_of_hosts ) {
179
- + ptr->live_host_indices = (uint32_t *)ptr->call_realloc(ptr, ptr->live_host_indices, sizeof(uint32_t) * ptr->number_of_live_hosts);
179
+ + ptr->live_host_indices = (uint32_t *)ptr->call_realloc(ptr, ptr->live_host_indices, sizeof(uint32_t) * ptr->number_of_hosts);
180
180
  + ptr->live_host_indices_size = ptr->number_of_live_hosts;
181
181
  + }
182
182
  +
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{memcached}
5
- s.version = "0.17.1"
5
+ s.version = "0.17.2"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Evan Weaver"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: memcached
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.17.1
4
+ version: 0.17.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Evan Weaver
metadata.gz.sig CHANGED
Binary file