summaryrefslogtreecommitdiff
path: root/json_util.c
diff options
context:
space:
mode:
Diffstat (limited to 'json_util.c')
-rw-r--r--json_util.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/json_util.c b/json_util.c
index cab2f1e..531f9af 100644
--- a/json_util.c
+++ b/json_util.c
@@ -99,7 +99,7 @@ struct json_object* json_object_from_file(const char *filename)
/* extended "format and write to file" function */
-int json_object_to_file_ext(char *filename, struct json_object *obj, int flags)
+int json_object_to_file_ext(const char *filename, struct json_object *obj, int flags)
{
const char *json_str;
int fd, ret;
@@ -141,7 +141,7 @@ int json_object_to_file_ext(char *filename, struct json_object *obj, int flags)
// backwards compatible "format and write to file" function
-int json_object_to_file(char *filename, struct json_object *obj)
+int json_object_to_file(const char *filename, struct json_object *obj)
{
return json_object_to_file_ext(filename, obj, JSON_C_TO_STRING_PLAIN);
}