Parser bug fixes. NullPointerException handled