Fix IOError during setup