Eliminate use of MC_ABORT in json-c code, and mark MC_ABORT/mc_abort deprecated.

Also adjust an error message in json_util to make it unique.  Fixes #87.
This commit is contained in:
Eric Haszlakiewicz
2013-06-29 15:31:18 -05:00
parent be002fbb96
commit b3bce4d594
2 changed files with 9 additions and 2 deletions

View File

@@ -73,7 +73,7 @@ struct json_object* json_object_from_file(const char *filename)
int fd, ret;
if((fd = open(filename, O_RDONLY)) < 0) {
MC_ERROR("json_object_from_file: error reading file %s: %s\n",
MC_ERROR("json_object_from_file: error opening file %s: %s\n",
filename, strerror(errno));
return NULL;
}
@@ -87,7 +87,7 @@ struct json_object* json_object_from_file(const char *filename)
}
close(fd);
if(ret < 0) {
MC_ABORT("json_object_from_file: error reading file %s: %s\n",
MC_ERROR("json_object_from_file: error reading file %s: %s\n",
filename, strerror(errno));
printbuf_free(pb);
return NULL;