ID: 50271 Updated by: j...@php.net Reported By: RQuadling at GMail dot com Status: Open -Bug Type: Unknown/Other Function +Bug Type: Program Execution Operating System: win32 only - Windows XP SP3 PHP Version: 5.3SVN-2009-11-23 (SVN) New Comment:
FYI: In the future when a bug is clearly windows only, use os prefix 'win32 only -' to preserve my sanity.. Previous Comments: ------------------------------------------------------------------------ [2009-11-23 13:15:31] RQuadling at GMail dot com Description: ------------ In http://lxr.php.net/source/TSRM/tsrm_win32.c#52, the shell to execute is hardcoded. This should be retrieved via GetEnvironmentVariable('COMSPEC', ...); As such, any program called cmd.exe (or command.com for older, and now unsupported by PHP, versions of windows) in a directory accessible via the PATH _before_ the actual location of cmd.exe/command.com will be loaded for the shell. The environment variable "COMSPEC" (now known as "ComSpec", but is case insensitive for Windows) by default includes the path. Whilst this is not a series bug, it does mean PHP conforms to other languages and applications that can invoke a console shell via COMSPEC, rather than using a hard-coded name. Considering that PHP doesn't support older versions of windows any longer, the whole test on GetVersion() is also redundant. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=50271&edit=1