|
@@ -168,14 +168,13 @@ if(redis_cmd("srvN", "HMGET foo_key field1 field3", "r")) {
|
|
<function moreinfo="none">redis_free(replyid)</function>
|
|
<function moreinfo="none">redis_free(replyid)</function>
|
|
</title>
|
|
</title>
|
|
<para>
|
|
<para>
|
|
- Free a previous reply from memory.
|
|
|
|
|
|
+ Frees data in a previous reply from memory.
|
|
After this function call, accessing to a freed replyid returns null value.
|
|
After this function call, accessing to a freed replyid returns null value.
|
|
</para>
|
|
</para>
|
|
<para>
|
|
<para>
|
|
It is not necessary to free a reply to use it again in a new redis_cmd
|
|
It is not necessary to free a reply to use it again in a new redis_cmd
|
|
function. When ndb_redis module closes, all pending replies are freed
|
|
function. When ndb_redis module closes, all pending replies are freed
|
|
- automatically, so you only need to use this function if you perform a
|
|
|
|
- lot of redis command requests with different replyid.
|
|
|
|
|
|
+ automatically.
|
|
</para>
|
|
</para>
|
|
<example>
|
|
<example>
|
|
<title><function>redis_free</function> usage</title>
|
|
<title><function>redis_free</function> usage</title>
|
|
@@ -184,7 +183,7 @@ if(redis_cmd("srvN", "HMGET foo_key field1 field3", "r")) {
|
|
After a redis command call:
|
|
After a redis command call:
|
|
redis_cmd("srvN", "INCR cnt", "r");
|
|
redis_cmd("srvN", "INCR cnt", "r");
|
|
|
|
|
|
-when reply not used anymore:
|
|
|
|
|
|
+free reply data:
|
|
redis_free("r");
|
|
redis_free("r");
|
|
...
|
|
...
|
|
</programlisting>
|
|
</programlisting>
|