changeset 36001:1d402a57bb21

(init-environment): Duplicate local string before putenv.
author Jason Rumney <jasonr@gnu.org>
date Fri, 09 Feb 2001 09:57:04 +0000
parents f4a0b086cc5d
children 205727d5d63c
files src/w32.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/w32.c	Fri Feb 09 09:55:43 2001 +0000
+++ b/src/w32.c	Fri Feb 09 09:57:04 2001 +0000
@@ -704,7 +704,7 @@
 	{
 	  char * var = alloca (strlen (tmp) + 8);
 	  sprintf (var, "TMPDIR=%s", tmp);
-	  _putenv (var);
+	  _putenv (strdup (var));
 	  break;
 	}
     }