=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/tmux/window.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- src/usr.bin/tmux/window.c 2009/06/01 22:58:49 1.1 +++ src/usr.bin/tmux/window.c 2009/06/05 07:18:37 1.2 @@ -1,4 +1,4 @@ -/* $OpenBSD: window.c,v 1.1 2009/06/01 22:58:49 nicm Exp $ */ +/* $OpenBSD: window.c,v 1.2 2009/06/05 07:18:37 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott @@ -473,7 +473,7 @@ if (chdir(wp->cwd) != 0) chdir("/"); for (envq = envp; *envq != NULL; envq++) { - if (putenv((char *) *envq) != 0) + if (putenv(xstrdup(*envq)) != 0) fatal("putenv failed"); } sigreset();