process: improve `--redirect-warnings` handling
- Acquiring the file descriptor is not observable anymore when using
the
--redirect-warnings
flag. - If
fs.appendFile
fails, the warning is now redirected to the default output. - The code is much smaller and simpler.
Checklist
-
make -j4 test
(UNIX), orvcbuild test
(Windows) passes -
tests and/or benchmarks are included -
documentation is changed or added -
commit message follows commit guidelines