Fix input read when asking for an action with -wait-fail