]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
Free my_hostdomain at deinit.
authorTimo Sirainen <tss@iki.fi>
Mon, 18 Feb 2013 04:49:57 +0000 (06:49 +0200)
committerTimo Sirainen <tss@iki.fi>
Mon, 18 Feb 2013 04:49:57 +0000 (06:49 +0200)
src/lib/hostpid.c
src/lib/hostpid.h
src/lib/lib.c

index 01e1cc238e0dbdbe086c6b2abff4e6ee141be1a8..1dfac4096ce6cd6e573bafe714d2c05e974f98ff 100644 (file)
@@ -32,6 +32,11 @@ void hostpid_init(void)
        my_pid = pid;
 }
 
+void hostpid_deinit(void)
+{
+       i_free(my_domain);
+}
+
 const char *my_hostdomain(void)
 {
        struct hostent *hent;
index d6ccffeea8ce8d824faa1222df00e221594715bb..4e92837651900da731909fbad94fac9a9318f87e 100644 (file)
@@ -6,6 +6,7 @@ extern const char *my_pid;
 
 /* 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. */
index bf6816878b07c69177038eda0f55b62ab2386eae..daf4910eefb77fba357b675342e955a9d81b26a4 100644 (file)
@@ -77,6 +77,7 @@ void lib_deinit(void)
        }
 
        ipwd_deinit();
+       hostpid_deinit();
        data_stack_deinit();
        env_deinit();
        failures_deinit();