Tweak le_set() for clarity in msystem.cpp
This commit is contained in:
parent
c931a13ecd
commit
be0b374cad
|
@ -405,13 +405,18 @@ char *env;
|
|||
*/
|
||||
size_t p_size=0;
|
||||
if (strchr(env, '=') == NULL) {
|
||||
|
||||
q = getenv(env);
|
||||
|
||||
/* is it defined locally? */
|
||||
if ((q = getenv(env)) == NULL){
|
||||
if (NULL == q) {
|
||||
/* no -- don't define it here */
|
||||
return(SE_NONE);
|
||||
}
|
||||
else if ((p = (char*)malloc((unsigned) (p_size = (strlen(env)+strlen(q)+2))))
|
||||
== NULL){
|
||||
|
||||
size_t p_size = strlen(env) + strlen(q) + 2;
|
||||
|
||||
if ((p = (char*)malloc((unsigned)(p_size))) == NULL) {
|
||||
ERMSG("ran out of memory");
|
||||
return(SE_NOMEM);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue