mirror of
https://github.com/sheumann/hush.git
synced 2024-12-22 14:30:31 +00:00
applying fix for:
0000261: Unsafe empty env var export in ash
This commit is contained in:
parent
01f67987e0
commit
6f267f022f
@ -12001,9 +12001,8 @@ setvar(const char *name, const char *val, int flags)
|
||||
}
|
||||
INTOFF;
|
||||
p = mempcpy(nameeq = ckmalloc(namelen + vallen + 2), name, namelen);
|
||||
*p++ = '\0';
|
||||
*p++ = '=';
|
||||
if (vallen) {
|
||||
p[-1] = '=';
|
||||
p = mempcpy(p, val, vallen);
|
||||
}
|
||||
*p = '\0';
|
||||
|
Loading…
Reference in New Issue
Block a user