fix sprintfdirectives, which returns an int