> When calling ExecuteWithLog with a redirection (using > or, possibly, <), the 
> entire command needs to be executed in a subshell, that is, inside a pair of 
> parentheses. This is the callers obligation to ensure, but we have proven 
> multiple times that this is hard to keep in mind, and we got several cases of 
> race conditions due to missing this.
> 
> This PR changes the implementation of ExecuteWithLog so it checks if the 
> command line contains redirection, and automatically add the subshell 
> parentheses in that case. The alternative would have been to always execute 
> in a subshell, but that would have been very expensive on Windows.

Magnus Ihse Bursie has updated the pull request incrementally with two 
additional commits since the last revision:

 - Break all lines to fit in 80 chars
 - Break long lines

-------------

Changes:
  - all: https://git.openjdk.org/jdk/pull/27096/files
  - new: https://git.openjdk.org/jdk/pull/27096/files/c5111837..768eec07

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=27096&range=02
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=27096&range=01-02

  Stats: 11 lines in 1 file changed: 7 ins; 0 del; 4 mod
  Patch: https://git.openjdk.org/jdk/pull/27096.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/27096/head:pull/27096

PR: https://git.openjdk.org/jdk/pull/27096

Reply via email to