3 ms·
freopen() has been around and working as intended on Win32 for ages. And this works for all userspace in the same process (i.e. it's not just FILE* that gets re
by int_19h 7y ago
freopen() has been around and working as intended on Win32 for ages. And this works for all userspace in the same process (i.e. it's not just FILE* that gets redirected, but everything going to stdout regardless of how it gets there). So I'm not sure why the kernel side of it would matter?
dup2() is there as well: https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/dup-dup2?view=vs-2019 https://docs.microsoft.com/en-us/cpp/c-runtime-library/refer...