jsonparser: Throw an error when the JSON input is not an object

syslog-ng assumes that the JSON input the parser receives will be an
object, if it is not, we should throw an error. The most likely case is
a miss-parse, we should not try to be clever there, but fail instead
with a sensible message.

Signed-off-by: Gergely Nagy <algernon@balabit.hu>
json-parser: When parsing fails, tag the error with the input

When JSON parsing fails with returning a NULL object, add the original
input to the emitted error message, for easier debugging.

Signed-off-by: Gergely Nagy <algernon@balabit.hu>