Fix writing of command line args to file on Visual C++