eina: uninitialization of array leads to unwanted outcome of "eina_strlcat"
authorPrince Kumar Dubey <prince.dubey@samsung.com>
Fri, 13 Oct 2017 19:03:52 +0000 (12:03 -0700)
committerCedric Bail <cedric@osg.samsung.com>
Fri, 13 Oct 2017 19:03:55 +0000 (12:03 -0700)
Reviewers: raster, cedric, rajeshps

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5297

Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
src/examples/eina/eina_simple_xml_parser_01.c

index de27e0b..a4f6ca4 100644 (file)
@@ -63,7 +63,7 @@ _xml_tag_cb(void *data, Eina_Simple_XML_Type type, const char *content,
 {
    char buffer[length+1];
    Eina_Array *array = data;
-   char str[512];
+   char str[512] = {'\0'};
 
    if (type == EINA_SIMPLE_XML_OPEN)
      {