From fca87f657597ea621a5683d334959c5a617edbd7 Mon Sep 17 00:00:00 2001 From: Steve Date: Sat, 3 Mar 2018 16:04:40 +0000 Subject: [PATCH] Use MAX_DESCRIPTION_LENGTH to prevent target name truncation. --- src/entities/structures/powerPoint.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/entities/structures/powerPoint.c b/src/entities/structures/powerPoint.c index b7cfb91..a26d142 100644 --- a/src/entities/structures/powerPoint.c +++ b/src/entities/structures/powerPoint.c @@ -144,7 +144,7 @@ static void load(cJSON *root) s = (Structure*)self; s->requiredPower = cJSON_GetObjectItem(root, "requiredPower")->valueint; - STRNCPY(s->targetNames, cJSON_GetObjectItem(root, "targetNames")->valuestring, MAX_NAME_LENGTH); + STRNCPY(s->targetNames, cJSON_GetObjectItem(root, "targetNames")->valuestring, MAX_DESCRIPTION_LENGTH); } static void save(cJSON *root)