From a9d52e3b7925ef119b5d0d9fca14faac634effb0 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Sat, 31 Jul 2010 16:44:19 +0200 Subject: Fixes for coverity warnings. --- src/ex_getln.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/ex_getln.c') diff --git a/src/ex_getln.c b/src/ex_getln.c index b292f6391..790d5315a 100644 --- a/src/ex_getln.c +++ b/src/ex_getln.c @@ -3780,7 +3780,7 @@ vim_strsave_fnameescape(fname, shell) /* '>' and '+' are special at the start of some commands, e.g. ":edit" and * ":write". "cd -" has a special meaning. */ - if (*p == '>' || *p == '+' || (*p == '-' && p[1] == NUL)) + if (p != NULL && (*p == '>' || *p == '+' || (*p == '-' && p[1] == NUL))) escape_fname(&p); return p; -- cgit v1.2.3