Fix error reporting during schema parsing

:Release Notes:
Fixed case when error occurred during schema parsing but schema was
parsed entirely.

:Detailed Notes:

:Testing Performed:
Unit tests with memcheck

:QA Notes:

:Issues Addressed:
[ANG-301] pbnjson: Provide more detailed error reporting during schema
          parsing

Open-webOS-DCO-1.0-Signed-off-by: Mykola Kryvonos <mykola.kryvonos@lge.com>

Change-Id: I445eac21a18bed371d27788bc634a344cc150ab7
Reviewed-on: https://g2g.palm.com/4306
Reviewed-by: DCO Verification
Reviewed-by: Anatolii Sakhnik <anatolii.sakhnik@lge.com>
Reviewed-by: Mykola Kryvonos <mykola.kryvonos@lge.com>
Tested-by: Mykola Kryvonos <mykola.kryvonos@lge.com>
Reviewed-on: https://g2g.palm.com/4622