summaryrefslogtreecommitdiff
path: root/json_util.c
diff options
context:
space:
mode:
Diffstat (limited to 'json_util.c')
-rw-r--r--json_util.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/json_util.c b/json_util.c
index 1c1fa46..b7c25af 100644
--- a/json_util.c
+++ b/json_util.c
@@ -282,3 +282,10 @@ const char *json_type_to_name(enum json_type o_type)
return json_type_name[o_type];
}
+void json_abort(const char *message)
+{
+ if (message != NULL)
+ fprintf (stderr, "json-c aborts with error: %s\n", message);
+ abort();
+}
+