changeset 79222:0ff71882c6a7

(init_environment): Fix tiny memory leak.
author Juanma Barranquero <lekktu@gmail.com>
date Thu, 25 Oct 2007 10:34:36 +0000
parents dea51733fd48
children a90155608ffc
files src/w32.c
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/w32.c	Thu Oct 25 04:09:35 2007 +0000
+++ b/src/w32.c	Thu Oct 25 10:34:36 2007 +0000
@@ -1112,6 +1112,7 @@
 		/* Also ignore empty environment variables.  */
 		|| *lpval == 0)
 	      {
+		if (lpval) xfree (lpval);
 		lpval = env_vars[i].def_value;
 		dwType = REG_EXPAND_SZ;
 		dont_free = 1;