Added parsing error control