am fed0f06b: Merge "init: Fix memory corruption when sanitizing platform paths"
* commit 'fed0f06bf04c6de90ae7b2f8ae9158ab2200498e': init: Fix memory corruption when sanitizing platform paths
This commit is contained in:
commit
ae3a8961f0
1 changed files with 2 additions and 2 deletions
|
|
@ -329,9 +329,9 @@ void sanitize(char *s)
|
|||
if (!s)
|
||||
return;
|
||||
|
||||
for (; *s; s++) {
|
||||
while (*s) {
|
||||
s += strspn(s, accept);
|
||||
if (*s) *s = '_';
|
||||
if (*s) *s++ = '_';
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue