s/_alloca/alloca/g; Windows doesn't need the former, at least not unless
__STDC__ is defined (or something like that ...).
This commit is contained in:
parent
0f345567fe
commit
92e4dd8657
|
@ -3606,7 +3606,7 @@ _PyPopenCreateProcess(char *cmdstring,
|
||||||
if (i = GetEnvironmentVariable("COMSPEC",NULL,0)) {
|
if (i = GetEnvironmentVariable("COMSPEC",NULL,0)) {
|
||||||
char *comshell;
|
char *comshell;
|
||||||
|
|
||||||
s1 = (char *)_alloca(i);
|
s1 = (char *)alloca(i);
|
||||||
if (!(x = GetEnvironmentVariable("COMSPEC", s1, i)))
|
if (!(x = GetEnvironmentVariable("COMSPEC", s1, i)))
|
||||||
return x;
|
return x;
|
||||||
|
|
||||||
|
@ -3622,7 +3622,7 @@ _PyPopenCreateProcess(char *cmdstring,
|
||||||
_stricmp(comshell, "command.com") != 0) {
|
_stricmp(comshell, "command.com") != 0) {
|
||||||
/* NT/2000 and not using command.com. */
|
/* NT/2000 and not using command.com. */
|
||||||
x = i + strlen(s3) + strlen(cmdstring) + 1;
|
x = i + strlen(s3) + strlen(cmdstring) + 1;
|
||||||
s2 = (char *)_alloca(x);
|
s2 = (char *)alloca(x);
|
||||||
ZeroMemory(s2, x);
|
ZeroMemory(s2, x);
|
||||||
PyOS_snprintf(s2, x, "%s%s%s", s1, s3, cmdstring);
|
PyOS_snprintf(s2, x, "%s%s%s", s1, s3, cmdstring);
|
||||||
}
|
}
|
||||||
|
@ -3675,7 +3675,7 @@ _PyPopenCreateProcess(char *cmdstring,
|
||||||
strlen(modulepath) +
|
strlen(modulepath) +
|
||||||
strlen(szConsoleSpawn) + 1;
|
strlen(szConsoleSpawn) + 1;
|
||||||
|
|
||||||
s2 = (char *)_alloca(x);
|
s2 = (char *)alloca(x);
|
||||||
ZeroMemory(s2, x);
|
ZeroMemory(s2, x);
|
||||||
/* To maintain correct argument passing semantics,
|
/* To maintain correct argument passing semantics,
|
||||||
we pass the command-line as it stands, and allow
|
we pass the command-line as it stands, and allow
|
||||||
|
|
|
@ -1450,9 +1450,9 @@ int
|
||||||
PyOS_CheckStack(void)
|
PyOS_CheckStack(void)
|
||||||
{
|
{
|
||||||
__try {
|
__try {
|
||||||
/* _alloca throws a stack overflow exception if there's
|
/* alloca throws a stack overflow exception if there's
|
||||||
not enough space left on the stack */
|
not enough space left on the stack */
|
||||||
_alloca(PYOS_STACK_MARGIN * sizeof(void*));
|
alloca(PYOS_STACK_MARGIN * sizeof(void*));
|
||||||
return 0;
|
return 0;
|
||||||
} __except (EXCEPTION_EXECUTE_HANDLER) {
|
} __except (EXCEPTION_EXECUTE_HANDLER) {
|
||||||
/* just ignore all errors */
|
/* just ignore all errors */
|
||||||
|
|
Loading…
Reference in New Issue