Updated PP 5.3 to use sentinel value to decide whether to quit