https://issues.dlang.org/show_bug.cgi?id=13367
Issue ID: 13367
Summary: Buffer overflow when setting PATH
Product: D
Version: unspecified
Hardware: All
OS: All
Status: NEW
Severity: regression
Priority: P1
Component: Phobos
Assignee: [email protected]
Reporter: [email protected]
/////////////////////////// testPath.d ///////////////////////////
import std.process;
void main()
{
foreach (n; 0..50)
environment["PATH"] = environment["PATH"] ~ `;C:\Example`;
}
//////////////////////////////////////////////////////////////////
This program will freeze on Win32 and crash on Win64. The stack trace is
corrupted, I assume a buffer on the stack is being overflown.
Introduced in https://github.com/D-Programming-Language/phobos/pull/2332
--