From 72078d032f9bf963a62c86a8dda5cfcc05b0de5d Mon Sep 17 00:00:00 2001 From: Han-Wen Nienhuys Date: Tue, 16 Jan 2007 23:49:16 +0100 Subject: [PATCH] document memory leak in relocate.cc --- lily/relocate.cc | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lily/relocate.cc b/lily/relocate.cc index ac4c31bac4..d7aed8133c 100644 --- a/lily/relocate.cc +++ b/lily/relocate.cc @@ -43,7 +43,12 @@ sane_putenv (char const *key, string value, bool overwrite) if (be_verbose_global) progress_indication (_f ("Setting %s to %s\n" , key, value.c_str ())); - return putenv (s); + int retval = putenv (s); + /* + unfortunately, we can't portably free S here, + due to various bugs in glibc prior to 2.1.1 + */ + return retval; } return -1; -- 2.39.5