summaryrefslogtreecommitdiff
path: root/hiredis.c
diff options
context:
space:
mode:
authorMareq <mareq@balint.eu>2014-07-04 16:36:18 +0100
committerMatt Stancliff <matt@genges.com>2015-01-05 16:39:30 -0500
commit1b392eb796ed3853392109dfadb34a98fa37d61b (patch)
tree294d2ab7614d77affa3894c718417693a7a3025c /hiredis.c
parent85c6bfb02a2dacb9ccd0885f8c1cf807447ae1eb (diff)
Add API to free hiredis (char *) formattings
[Cleaned up: - name of function: freeRedis... -> redisFree... - return value of function (free doesn't return anything) - parameter type for function. - we don't need to free a char**, the char** is just for returning from the assignment functoin.] Closes #250
Diffstat (limited to 'hiredis.c')
-rw-r--r--hiredis.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/hiredis.c b/hiredis.c
index be67658..34198fc 100644
--- a/hiredis.c
+++ b/hiredis.c
@@ -1027,6 +1027,10 @@ int redisFormatCommandArgv(char **target, int argc, const char **argv, const siz
return totlen;
}
+void redisFreeCommand(char *cmd) {
+ free(cmd);
+}
+
void __redisSetError(redisContext *c, int type, const char *str) {
size_t len;