Browse Source

TT#108003 Fix double free in __established()

The __attempt_send() function will free the gs string on success,
so we should not free it again.

Change-Id: I74c9e41854db56bf29ae541eaeebfb97ce8eeb74
Warned-by: coverity
pull/1194/head
Guillem Jover 5 years ago
parent
commit
009aa21bc0
1 changed files with 0 additions and 1 deletions
  1. +0
    -1
      daemon/homer.c

+ 0
- 1
daemon/homer.c View File

@ -116,7 +116,6 @@ static int __established(struct homer_sender *hs) {
if (ret == 1) // write error, takes care of deleting hs->partial if (ret == 1) // write error, takes care of deleting hs->partial
return -1; return -1;
// ret == 0 -> sent OK, drop through to unqueue // ret == 0 -> sent OK, drop through to unqueue
g_string_free(hs->partial, TRUE);
hs->partial = NULL; hs->partial = NULL;
} }


Loading…
Cancel
Save