Fix logging networks with invalid names on Windows