Fix compatibility with older versions of the YAJL library

refs #7454