Provide a Windows-specific implementation of exec_program_v()

Building in Visual Studio 2010 causes clients to hang if they
read stdout (Far Manager, for example). This does not happen for
MinGW builds, so this rough hack uses Win32 handles for
redirection, rather than C file-descriptors.

[JES: formatted source code a little bit, moved around a little
bit, simplified integration of the Windows-specific code.]

Signed-off-by: johnstevenson <john-stevenson@blueyonder.co.uk>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Use Win32 API for output redirection

Building in Visual Studio 2010 causes clients to hang if they
read stdout (Far Manager, for example). This does not happen for
mingw builds, so this rough hack uses Win32 handles for
redirection, rather than C file-descriptors, to see if the
problem is caused by a bad C implementation.

Signed-off-by: johnstevenson <john-stevenson@blueyonder.co.uk>