From d5473281c4e81780c0644f8f6c2889d838d29bd5 Mon Sep 17 00:00:00 2001 From: Virgilio Pigliucci Date: Thu, 31 Jan 2013 10:36:11 -0800 Subject: [PATCH 1/2] Update lib/dalli/ring.rb Removing another C warning ( implicit conversion long to int ) --- lib/dalli/ring.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/dalli/ring.rb b/lib/dalli/ring.rb index 5ee0af0d..11c23402 100644 --- a/lib/dalli/ring.rb +++ b/lib/dalli/ring.rb @@ -79,9 +79,9 @@ def entry_count_for(server, total_servers, total_weight) inline do |builder| builder.c <<-EOM int binary_search(VALUE ary, unsigned int r) { - int upper = RARRAY_LEN(ary) - 1; - int lower = 0; - int idx = 0; + long upper = RARRAY_LEN(ary) - 1; + long lower = 0; + long idx = 0; ID value = rb_intern("value"); VALUE continuumValue; unsigned int l; From 240b1155f18ae2962052d67e0d7337a80a35a4ad Mon Sep 17 00:00:00 2001 From: Stefan Wille Date: Wed, 27 Feb 2013 13:59:06 +0100 Subject: [PATCH 2/2] Reflect default 0 for TTL in the README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 99adad14..eedfda91 100644 --- a/README.md +++ b/README.md @@ -114,7 +114,7 @@ Configuration ------------------------ Dalli::Client accepts the following options. All times are in seconds. -**expires_in**: Global default for key TTL. No default. +**expires_in**: Global default for key TTL. Default is 0, which means no expiry. **failover**: Boolean, if true Dalli will failover to another server if the main server for a key is down.