From: cedric Date: Wed, 20 Jan 2010 12:41:22 +0000 (+0000) Subject: * ecore: Handle NULL in ecore_file_dir_get. X-Git-Tag: build/2012-07-04.173327~2260 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b73c5b5d18f70543f17ca84e04cb3f35e43cd8e9;p=profile%2Fivi%2Fecore.git * ecore: Handle NULL in ecore_file_dir_get. git-svn-id: http://svn.enlightenment.org/svn/e/trunk/ecore@45352 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/lib/ecore_file/ecore_file.c b/src/lib/ecore_file/ecore_file.c index 1bfcaee..2dcff23 100644 --- a/src/lib/ecore_file/ecore_file.c +++ b/src/lib/ecore_file/ecore_file.c @@ -600,6 +600,7 @@ ecore_file_dir_get(const char *file) char *p; char buf[PATH_MAX]; + if (!file) return NULL; strncpy(buf, file, PATH_MAX); p = dirname(buf); return strdup(p);