Skip to content

Commit

Permalink
cygwin: use CREATE_DEFAULT_ERROR_MODE in spawn
Browse files Browse the repository at this point in the history
This allows native processes to get Windows-default error handling
behavior (such as invoking the registered JIT debugger), while cygwin
processes would quickly set their error mode back to what they expect.
  • Loading branch information
jeremyd2019 committed Nov 8, 2020
1 parent e68ccdf commit c48d6a7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion winsup/cygwin/spawn.cc
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,8 @@ child_info_spawn::worker (const char *prog_arg, const char *const *argv,
c_flags = GetPriorityClass (GetCurrentProcess ());
sigproc_printf ("priority class %d", c_flags);

c_flags |= CREATE_SEPARATE_WOW_VDM | CREATE_UNICODE_ENVIRONMENT;
c_flags |= CREATE_SEPARATE_WOW_VDM | CREATE_UNICODE_ENVIRONMENT
| CREATE_DEFAULT_ERROR_MODE;

/* We're adding the CREATE_BREAKAWAY_FROM_JOB flag here to workaround
issues with the "Program Compatibility Assistant (PCA) Service".
Expand Down

0 comments on commit c48d6a7

Please sign in to comment.