Skip to content

Commit

Permalink
Make _set_last_err() non-static so it can be used outside of json_util.c
Browse files Browse the repository at this point in the history
  • Loading branch information
hawicz committed Jun 18, 2017
1 parent e76ea37 commit 8581806
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 2 additions & 0 deletions json_object_private.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ struct json_object
void *_userdata;
};

void _set_last_err(const char *err_fmt, ...);

#ifdef __cplusplus
}
#endif
Expand Down
3 changes: 1 addition & 2 deletions json_util.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@
static int sscanf_is_broken = 0;
static int sscanf_is_broken_testdone = 0;
static void sscanf_is_broken_test(void);
static void _set_last_err(const char *err_fmt, ...);

static char _last_err[256] = "";

Expand All @@ -75,7 +74,7 @@ const char *json_util_get_last_err()
return _last_err;
}

static void _set_last_err(const char *err_fmt, ...)
void _set_last_err(const char *err_fmt, ...)
{
va_list ap;
va_start(ap, err_fmt);
Expand Down

0 comments on commit 8581806

Please sign in to comment.