edje edje_embryo: use strncpy().

This change is not meaningful but avoids an annoying coverity detection.
This commit is contained in:
Hermet Park 2016-09-21 15:03:11 +09:00
parent ab1a72f5e7
commit 06bd8dcf33
1 changed files with 3 additions and 4 deletions

View File

@ -1553,10 +1553,9 @@ _edje_embryo_fn_get_text(Embryo_Program *ep, Embryo_Cell *params)
}
else
{
char *ss;
ss = alloca(strlen(s) + 1);
strcpy(ss, s);
int size = strlen(s) + 1;
char *ss = alloca(size);
strncpy(ss, s, size);
ss[params[3] - 1] = 0;
SETSTR(ss, params[2]);
}