Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c00df0b

Browse files
committed
Trigger keep-console-open on GUSISIOUX_STATE_UNKNOWN. Better than the previous complicated expression.
1 parent f50fbf1 commit c00df0b

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

Mac/Python/macmain.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ init_common(int *argcp, char ***argvp, int embedded)
283283
} else {
284284
/* Create argc/argv. Do it before we go into the options event loop. */
285285
*argcp = PyMac_GetArgv(argvp, PyMac_options.noargs);
286-
#ifdef USE_ARGV0_CHDIR
286+
#ifndef NO_ARGV0_CHDIR
287287
if (*argcp >= 1 && (*argvp)[0] && (*argvp)[0][0]) {
288288
/* Workaround for MacOS X, which currently (DP4) doesn't set
289289
** the working folder correctly
@@ -544,7 +544,7 @@ Py_Main(argc, argv)
544544
void
545545
PyMac_OutputSeen()
546546
{
547-
#if defined(USE_GUSI) && !TARGET_API_MAC_CARBON_NOTYET
547+
#ifdef GUSISIOUX_STATE_UNKNOWN
548548
gusisioux_state = GUSISIOUX_STATE_LASTREAD;
549549
#endif
550550
}
@@ -569,7 +569,7 @@ PyMac_Exit(status)
569569
keep = 0;
570570
break;
571571
case POPT_KEEPCONSOLE_OUTPUT:
572-
#if defined(USE_GUSI) && !TARGET_API_MAC_CARBON_NOTYET
572+
#ifdef GUSISIOUX_STATE_UNKNOWN
573573
if (gusisioux_state == GUSISIOUX_STATE_LASTWRITE ||
574574
gusisioux_state == GUSISIOUX_STATE_UNKNOWN )
575575
keep = 1;

0 commit comments

Comments
 (0)