From b5d5b3378c959de9190be393e8af87bae7d98344 Mon Sep 17 00:00:00 2001 From: Gustavo Sverzut Barbieri Date: Tue, 9 Jun 2009 10:25:25 +0000 Subject: [PATCH] do not segfault on empty filename to escape. Avoid case where e_exec (and possible others) gives e_util_filename_escape() a NULL parameter, actually another bug, but does not hurt to safe guard this one. By: manio SVN revision: 40979 --- src/bin/e_utils.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/bin/e_utils.c b/src/bin/e_utils.c index a941ee349..177cbfe23 100644 --- a/src/bin/e_utils.c +++ b/src/bin/e_utils.c @@ -652,6 +652,7 @@ e_util_filename_escape(const char *filename) char *q; static char buf[4096]; + if (!filename) return NULL; p = filename; q = buf; while (*p)