Avoid calling globfree twice on failure.