summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2010-08-26 12:42:04 +0300
committerSergey Poznyakoff <gray@gnu.org.ua>2010-08-26 12:42:04 +0300
commit1cb4b8d7631f3a7a675510ddf3332bc28ddc5d2d (patch)
tree69d6e573cc268f676ccdc98f88fc2651f44422d9
parentd66dc3789bac5ab2a5f23c996ca73c6d4d1626f7 (diff)
downloadmailutils-1cb4b8d7631f3a7a675510ddf3332bc28ddc5d2d.tar.gz
mailutils-1cb4b8d7631f3a7a675510ddf3332bc28ddc5d2d.tar.bz2
Bugfix.
* mailbox/acl.c (expand_arg): Fix a memory leak.
-rw-r--r--mailbox/acl.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/mailbox/acl.c b/mailbox/acl.c
index 7fb2acd36..a3e3764f2 100644
--- a/mailbox/acl.c
+++ b/mailbox/acl.c
@@ -541,7 +541,10 @@ expand_arg (const char *cmdline, struct run_closure *rp, char **s)
addr.s_addr = htonl (addr.s_addr);
mu_vartab_define (vtab, "address", inet_ntoa (addr), 0);
if (mu_asprintf (&p, "%hu", ntohs (s_in->sin_port)) == 0)
- mu_vartab_define (vtab, "port", p, 0);
+ {
+ mu_vartab_define (vtab, "port", p, 0);
+ free (p);
+ }
}
break;

Return to:

Send suggestions and report system problems to the System administrator.