fork version
in debug mode print localized messages in right encoding
change DETACHED_PROCESS to CREATE_NO_WINDOW to not let grandchildren allocate consoles
don't fallback to current user if logon fails
redirect child to pipe pump instead of inherited socket
fix child blocked on simultaneous read/write attempt

This fix was not applicable to standard I/O redirected to socket,
because non-overlapped ReadFile(s)/WriteFile(s) fail on overlapped
socket which we have now.
fix thread unsafe environment preparation