forked from github/server
segmentation fault in export when a plane has no name (default plane).
This commit is contained in:
parent
077d7d8d49
commit
fb32ebcd18
|
@ -71,7 +71,7 @@ int json_export(stream * out, int flags) {
|
||||||
cJSON_AddNumberToObject(data, "y", p->miny);
|
cJSON_AddNumberToObject(data, "y", p->miny);
|
||||||
cJSON_AddNumberToObject(data, "width", p->maxx-p->minx);
|
cJSON_AddNumberToObject(data, "width", p->maxx-p->minx);
|
||||||
cJSON_AddNumberToObject(data, "height", p->maxy-p->miny);
|
cJSON_AddNumberToObject(data, "height", p->maxy-p->miny);
|
||||||
cJSON_AddStringToObject(data, "name", p->name);
|
if (p->name) cJSON_AddStringToObject(data, "name", p->name);
|
||||||
}
|
}
|
||||||
|
|
||||||
cJSON_AddItemToObject(root, "regions", json = cJSON_CreateObject());
|
cJSON_AddItemToObject(root, "regions", json = cJSON_CreateObject());
|
||||||
|
|
Loading…
Reference in New Issue