Skip to content
Snippets Groups Projects
Commit 0819c3a8 authored by Dan Fandrich's avatar Dan Fandrich
Browse files

Don't strdup an empty string

parent ad05b22d
No related branches found
No related tags found
No related merge requests found
......@@ -55,7 +55,7 @@ char *GetEnv(const char *variable)
if (env && strcmp("HOME",variable) == 0)
env = decc$translate_vms(env);
#endif
return env?strdup(env):NULL;
return (env && env[0])?strdup(env):NULL;
#endif
#endif
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment