summaryrefslogtreecommitdiff
path: root/src/lib/elementary
diff options
context:
space:
mode:
authorDerek Foreman <derekf@osg.samsung.com>2017-02-28 17:23:03 -0600
committerDerek Foreman <derekf@osg.samsung.com>2017-02-28 17:23:03 -0600
commit7359f0be6e80c818ea3067671fb5c84af5ec9aae (patch)
tree9c8ca7340cf8a67052261440029b6c12a5038575 /src/lib/elementary
parentd8edf70c327258975503cf81ff5e633bcab05d48 (diff)
elm_cnp: allocate space for null terminator in _wl_targets_converter
strcat needs room for a string terminator.
Diffstat (limited to 'src/lib/elementary')
-rw-r--r--src/lib/elementary/elm_cnp.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lib/elementary/elm_cnp.c b/src/lib/elementary/elm_cnp.c
index 5a32ad5aef..2954867d68 100644
--- a/src/lib/elementary/elm_cnp.c
+++ b/src/lib/elementary/elm_cnp.c
@@ -2484,6 +2484,7 @@ _wl_targets_converter(char *target, Wl_Cnp_Selection *sel EINA_UNUSED, void *dat
2484 len += strlen(_atoms[i].name) + strlen(sep); 2484 len += strlen(_atoms[i].name) + strlen(sep);
2485 } 2485 }
2486 } 2486 }
2487 len++; //terminating null byte
2487 aret = calloc(1, len * sizeof(char)); 2488 aret = calloc(1, len * sizeof(char));
2488 if (!aret) return EINA_FALSE; 2489 if (!aret) return EINA_FALSE;
2489 for (i = 0; i < CNP_N_ATOMS; i++) 2490 for (i = 0; i < CNP_N_ATOMS; i++)