• Vincent Vanackere's avatar
    syscall : add ProcAttr field to pass an unescaped command line on windows · f18a4e96
    Vincent Vanackere authored
    On windows, the command line is passed as a single null-terminated string. While the automatic parameter escaping done by syscall.StartProcess works fine with most Windows programs, some applications do their own custom parsing of the command line, in which case the automatic escaping becomes harmful.
    This CL adds a new extra CmdLine field to syscall.ProcAttr that will be used as the raw/unescaped command line if not empty.
    Fixes #1849.
    
    R=golang-dev, alex.brainman, bradfitz, rsc
    CC=golang-dev
    https://golang.org/cl/4548050
    f18a4e96
exec_windows.go 6.84 KB