New wrapper function around subprocess.Popen

New wrapper function around subprocess.Popen that handles stdin
correctly when on Windows (see issue #637)