From c53b61f8d4a809ab53e954594874285ca32d1b11 Mon Sep 17 00:00:00 2001 From: Ralph Corderoy Date: Sat, 22 Oct 2016 00:21:16 +0100 Subject: [PATCH] Replace `if (p) free(p)' with `mh_xfree(p)'. --- sbr/mf.c | 24 ++++++++---------------- 1 file changed, 8 insertions(+), 16 deletions(-) diff --git a/sbr/mf.c b/sbr/mf.c index 63b13ba4..ebd130d2 100644 --- a/sbr/mf.c +++ b/sbr/mf.c @@ -180,18 +180,12 @@ getadrx (const char *addrs, int eai) char *bp; struct adrx *adrxp = &adrxs2; - if (pers) - free (pers); - if (mbox) - free (mbox); - if (host) - free (host); - if (path) - free (path); - if (grp) - free (grp); - if (note) - free (note); + mh_xfree(pers); + mh_xfree(mbox); + mh_xfree(host); + mh_xfree(path); + mh_xfree(grp); + mh_xfree(note); pers = mbox = host = path = grp = note = NULL; err[0] = 0; @@ -297,10 +291,8 @@ again: ; return NOTOK; } case LX_COMA: - if (note) { - free (note); - note = NULL; - } + mh_xfree(note); + note = NULL; goto again; case LX_END: -- 2.56.0