dovecot-2.2: Free my_hostdomain at deinit.

dovecot at dovecot.org dovecot at dovecot.org
Mon Feb 18 06:50:10 EET 2013


details:   http://hg.dovecot.org/dovecot-2.2/rev/420477745a17
changeset: 15827:420477745a17
user:      Timo Sirainen <tss at iki.fi>
date:      Mon Feb 18 06:49:57 2013 +0200
description:
Free my_hostdomain at deinit.

diffstat:

 src/lib/hostpid.c |  5 +++++
 src/lib/hostpid.h |  1 +
 src/lib/lib.c     |  1 +
 3 files changed, 7 insertions(+), 0 deletions(-)

diffs (37 lines):

diff -r 6a67a1440e15 -r 420477745a17 src/lib/hostpid.c
--- a/src/lib/hostpid.c	Mon Feb 18 06:35:41 2013 +0200
+++ b/src/lib/hostpid.c	Mon Feb 18 06:49:57 2013 +0200
@@ -32,6 +32,11 @@
 	my_pid = pid;
 }
 
+void hostpid_deinit(void)
+{
+	i_free(my_domain);
+}
+
 const char *my_hostdomain(void)
 {
 	struct hostent *hent;
diff -r 6a67a1440e15 -r 420477745a17 src/lib/hostpid.h
--- a/src/lib/hostpid.h	Mon Feb 18 06:35:41 2013 +0200
+++ b/src/lib/hostpid.h	Mon Feb 18 06:49:57 2013 +0200
@@ -6,6 +6,7 @@
 
 /* Initializes my_hostname and my_pid. */
 void hostpid_init(void);
+void hostpid_deinit(void);
 
 /* Returns the current host+domain, or if it fails fallback to returning
    hostname. */
diff -r 6a67a1440e15 -r 420477745a17 src/lib/lib.c
--- a/src/lib/lib.c	Mon Feb 18 06:35:41 2013 +0200
+++ b/src/lib/lib.c	Mon Feb 18 06:49:57 2013 +0200
@@ -77,6 +77,7 @@
 	}
 
 	ipwd_deinit();
+	hostpid_deinit();
 	data_stack_deinit();
 	env_deinit();
 	failures_deinit();


More information about the dovecot-cvs mailing list