From 796b46c841e2a470ed9dbeed3f20d8d3cb65c15e Mon Sep 17 00:00:00 2001 From: Kitae Kim Date: Thu, 16 Oct 2014 14:19:31 +0900 Subject: [PATCH] maru_err_table: prevent double free case. Duplicate source path to avoid double free case becuase the path might be released at caller side. Change-Id: I3a3b2a3605c4c4fbca13c6496c898a0f8e268348 Signed-off-by: Kitae Kim --- tizen/src/util/maru_err_table.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tizen/src/util/maru_err_table.c b/tizen/src/util/maru_err_table.c index 4f34fab..ad7d03f 100644 --- a/tizen/src/util/maru_err_table.c +++ b/tizen/src/util/maru_err_table.c @@ -77,7 +77,7 @@ void maru_sighandler(int sig); char *get_canonical_path(char const *const path) { if ((int)g_path_is_absolute(path)) { - return (char *)path; + return (char *)g_strdup(path); } char *canonical_path; -- 2.7.4