Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

more asprin

  • Loading branch information...
commit 29151153d8a2e7bda8ca7ad3bda9b8da03c6cb5a 1 parent 45dd8a6
@keenerd keenerd authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 jshon.c
View
4 jshon.c
@@ -116,8 +116,8 @@ json_t* smart_loads(char* j_string)
{
json_t* json;
json_error_t error;
- char temp[strlen(j_string) + 3];
- snprintf(temp, strlen(j_string) + 3, "[%s]", j_string);
+ char *temp;
+ asprintf(&temp, "[%s]", j_string);
json = json_loads(temp, 0, &error);
if (!json)
{return json_string(j_string);}
Please sign in to comment.
Something went wrong with that request. Please try again.