don't crash when env var not set on startup

SVN revision: 73907
This commit is contained in:
Mike Blumenkrantz 2012-07-16 06:54:48 +00:00
parent cca3979f86
commit 722b65cebf
1 changed files with 2 additions and 1 deletions

View File

@ -158,7 +158,8 @@ _env_path_append(const char *env, const char *path)
int len = 0, len2 = 0;
p = getenv(env);
if (p) len = strlen(p);
if (!p) return;
len = strlen(p);
p2 = (char *)path;
if (p2) len2 = strlen(p2);
if (p && p2)