Fixed the termination statement for keyword recognition.