localmemcache 0.2.1 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION +1 -1
- data/site/index.html +2 -2
- data/src/localmemcache.h +1 -0
- data/src/ruby-binding/rblocalmemcache.c +8 -0
- metadata +2 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.2
|
data/site/index.html
CHANGED
@@ -13,7 +13,7 @@
|
|
13
13
|
an interface similar to memcached but for accessing local data instead of
|
14
14
|
remote data. It's based on <b>mmap()</b>'ed shared memory for maximum speed.
|
15
15
|
|
16
|
-
<h2>Changes for 0.2.1</h2>
|
16
|
+
<h2>2009-04-05: Changes for 0.2.1</h2>
|
17
17
|
|
18
18
|
<li>Fixed a bug that prevented setting values in the hashtable</li>
|
19
19
|
<li>Accessing a closed memory cache does no longer result in a crash</li>
|
@@ -27,7 +27,7 @@ recover from crashes.)</li>
|
|
27
27
|
used to override the default, which is <b>/var/tmp/localmemcache</b></li>
|
28
28
|
|
29
29
|
|
30
|
-
<h2>New features in 0.2.0</h2>
|
30
|
+
<h2>2009-03-30: New features in 0.2.0</h2>
|
31
31
|
|
32
32
|
<li><b>Logging</b>: In case your application is terminated while
|
33
33
|
accessing the shared memory (eg by <b>kill -9</b>), it is now able to
|
data/src/localmemcache.h
CHANGED
@@ -43,4 +43,5 @@ int local_memcache_check_namespace(const char *namespace, lmc_error_t *e);
|
|
43
43
|
const char *__local_memcache_get(local_memcache_t *lmc,
|
44
44
|
const char *key, size_t n_key, size_t *n_value);
|
45
45
|
|
46
|
+
int lmc_unlock_shm_region(const char *who, local_memcache_t *lmc);
|
46
47
|
#endif
|
@@ -3,6 +3,8 @@
|
|
3
3
|
*/
|
4
4
|
|
5
5
|
#include <ruby.h>
|
6
|
+
#include <sys/types.h>
|
7
|
+
#include <unistd.h>
|
6
8
|
#include "localmemcache.h"
|
7
9
|
|
8
10
|
#ifndef RSTRING_LEN
|
@@ -13,6 +15,11 @@
|
|
13
15
|
#define RSTRING_PTR(x) RSTRING(x)->ptr
|
14
16
|
#endif
|
15
17
|
|
18
|
+
|
19
|
+
#if RUBY_VERSION_CODE >= 190
|
20
|
+
#define ruby_errinfo rb_errinfo()
|
21
|
+
#endif
|
22
|
+
|
16
23
|
/* :nodoc: */
|
17
24
|
long long_value(VALUE i) { return NUM2LONG(rb_Integer(i)); }
|
18
25
|
/* :nodoc: */
|
@@ -215,6 +222,7 @@ static VALUE __LocalMemCache__keys(VALUE d) {
|
|
215
222
|
int success = local_memcache_iterate(get_LocalMemCache(obj),
|
216
223
|
(void *) &data, lmc_ruby_iter);
|
217
224
|
if (!success) { return Qnil; }
|
225
|
+
return Qnil;
|
218
226
|
}
|
219
227
|
|
220
228
|
/*
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: localmemcache
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sven C. Koehler
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-04-
|
12
|
+
date: 2009-04-06 00:00:00 +00:00
|
13
13
|
default_executable:
|
14
14
|
dependencies: []
|
15
15
|
|