From: Juanma Barranquero Date: Thu, 25 Oct 2007 10:38:42 +0000 (+0000) Subject: (init_environment): Fix tiny memory leak. X-Git-Tag: emacs-pretest-22.1.90~506 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a8d6819ab32b70c5ea71b22bde1601b99e646b4d;p=emacs.git (init_environment): Fix tiny memory leak. --- diff --git a/src/ChangeLog b/src/ChangeLog index c593aa83c0b..c5ebc4ab5a6 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2007-10-25 Juanma Barranquero + + * w32.c (init_environment): Fix tiny memory leak. + 2007-10-24 Jason Rumney * w32fns.c: Include math.h. diff --git a/src/w32.c b/src/w32.c index 2b54f3d59dc..743eac99e7c 100644 --- a/src/w32.c +++ b/src/w32.c @@ -1112,6 +1112,7 @@ init_environment (char ** argv) /* Also ignore empty environment variables. */ || *lpval == 0) { + if (lpval) xfree (lpval); lpval = env_vars[i].def_value; dwType = REG_EXPAND_SZ; dont_free = 1;