Here is the patch to a memory leak in omhiredis.


--
Pavel Levshin

From: Pavel Levshin <[email protected]>
Date: Fri, 25 Oct 2013 12:08:09 +0400
Subject: [PATCH] omhiredis: remove memory leak

---
 plugins/omhiredis/omhiredis.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/plugins/omhiredis/omhiredis.c b/plugins/omhiredis/omhiredis.c 
index 051ac0b..cb4e608 100644
--- a/plugins/omhiredis/omhiredis.c
+++ b/plugins/omhiredis/omhiredis.c
@@ -196,7 +196,7 @@ CODESTARTendTransaction
     for ( i = 0; i < pData->count; i++ ) {
         redisGetReply ( pData->conn, (void *)&pData->replies[i] );
         /*  TODO: add error checking here! */
-        free ( pData->replies[i] );
+        freeReplyObject ( pData->replies[i] );
     }
     free ( pData->replies );
     pData->count = 0;
--
1.7.1



_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of 
sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE 
THAT.

Reply via email to