-1 to indicate failure