From e6306760982c4aaa41d9ffc712ae6d6f643d7fe6 Mon Sep 17 00:00:00 2001 From: Hyunjee Kim Date: Thu, 13 Jul 2017 13:31:30 +0900 Subject: [PATCH] [TNEXT-1095] Fix tc error Change-Id: Idb4aa2651114060b035c51b1fbe77272257ff1f0 Signed-off-by: Hyunjee Kim --- src/utils_i18n_measure_format.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils_i18n_measure_format.cpp b/src/utils_i18n_measure_format.cpp index 38cc541..e4e38cf 100644 --- a/src/utils_i18n_measure_format.cpp +++ b/src/utils_i18n_measure_format.cpp @@ -85,9 +85,9 @@ int i18n_measure_format_format(i18n_measure_format_h measure_format, int32_t ulen = i18n_ustring_get_length(uchar_result); retv_if(ulen <= 0, I18N_ERROR_INVALID_PARAMETER); - free(*append_to); - *append_to = (char *) malloc(ulen + 1); + *append_to = NULL; + *append_to = (char *) malloc(ulen + 1); retv_if(*append_to == NULL, I18N_ERROR_OUT_OF_MEMORY); i18n_ustring_copy_au(*append_to, uchar_result); -- 2.34.1