The data removed from the stack is not the expected data. The expected data is the Interval value. Either the Interval value is not at the top of the stack or the stack is empty.
Ensure that the Interval value is being placed on the stack or there is enough storage for the stack.