From: Dmitry V. Levin Date: Fri, 25 Aug 2006 07:57:09 +0000 (+0400) Subject: vzctl enter: Fix off-by-one error which resulted to uninitialized PATH. X-Git-Url: http://git.openvz.org/?p=vzctl;a=commitdiff;h=24807ad04c47c4c799b9b7bb7188c07cdd9c31ca vzctl enter: Fix off-by-one error which resulted to uninitialized PATH. Signed-off-by: Dmitry V. Levin --- Index: vzctl-3.0.11/src/enter.c =================================================================== --- vzctl-3.0.11.orig/src/enter.c +++ vzctl-3.0.11/src/enter.c @@ -265,7 +265,7 @@ int do_enter(vps_handler *h, envid_t vei close(slave); if ((term = getenv("TERM")) != NULL) { snprintf(buf, sizeof(buf), "TERM=%s", term); - env[2] = buf; + env[3] = buf; } execve("/bin/bash", arg, env); execve("/bin/sh", arg, env);