Skip to content

Commit

Permalink
se repara violación de segmento json.formato()
Browse files Browse the repository at this point in the history
  • Loading branch information
Harry committed Feb 25, 2017
1 parent 1bd550e commit b7a7aac
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/libjson.c
Expand Up @@ -121,8 +121,8 @@ static json_t *__latino_a_json(lat_mv * mv, lat_objeto * element) {
__latino_a_json(mv,
(lat_objeto
*) ((hash_val *)
cur->
valor)->valor));
cur->valor)->
valor));
}
}
}
Expand Down Expand Up @@ -204,6 +204,10 @@ void lat_json_codificar(lat_mv * mv) {

void lat_json_formato(lat_mv * mv) {
lat_objeto *a = lat_desapilar(mv);
if (a->tipo == T_NULL) {
lat_apilar(mv, mv->objeto_nulo);
return;
}
int spaces = 4;
char *str = NULL;
json_t *root = NULL;
Expand Down

0 comments on commit b7a7aac

Please sign in to comment.