hermet pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=06bd8dcf330fe31891475c92aa340d4886f47e2b

commit 06bd8dcf330fe31891475c92aa340d4886f47e2b
Author: Hermet Park <her...@hermet.pe.kr>
Date:   Wed Sep 21 15:03:11 2016 +0900

    edje edje_embryo: use strncpy().
    
    This change is not meaningful but avoids an annoying coverity detection.
---
 src/lib/edje/edje_embryo.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/src/lib/edje/edje_embryo.c b/src/lib/edje/edje_embryo.c
index bb46310..c09c3ff 100644
--- a/src/lib/edje/edje_embryo.c
+++ b/src/lib/edje/edje_embryo.c
@@ -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]);
           }

-- 


Reply via email to