summaryrefslogtreecommitdiff
path: root/msg.c
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2008-03-29 12:14:28 +0100
committerMichael Biebl <biebl@debian.org>2008-03-29 12:14:28 +0100
commit45e27e9006d03436f21a47ed2a0b283503fa2d80 (patch)
treece5e579f8768383b1d9facd78f0737306b62647b /msg.c
parent3d4464215f5496ec5d9b95954bac9704f9c7b125 (diff)
downloadrsyslog-45e27e9006d03436f21a47ed2a0b283503fa2d80.tar.gz
Imported Upstream version 1.19.2upstream/1.19.2
Diffstat (limited to 'msg.c')
-rw-r--r--msg.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/msg.c b/msg.c
index 3ba92b1..30fe7d4 100644
--- a/msg.c
+++ b/msg.c
@@ -1615,12 +1615,10 @@ char *MsgGetProp(msg_t *pMsg, struct templateEntry *pTpe,
if(*(pRes + iLn - 1) == '\n') {
/* we have a LF! */
/* check if we need to obtain a private copy */
- if(pbMustBeFreed == 0) {
+ if(*pbMustBeFreed == 0) {
/* ok, original copy, need a private one */
pB = malloc((iLn + 1) * sizeof(char));
if(pB == NULL) {
- if(*pbMustBeFreed == 1)
- free(pRes);
*pbMustBeFreed = 0;
return "**OUT OF MEMORY**";
}