From 7ebd7605a5cff87fb20bea9cd3d7a59ea261060f Mon Sep 17 00:00:00 2001 From: bje Date: Thu, 14 Oct 2004 07:15:37 +0000 Subject: PR other/17900 * diagnostic.c (trim_filename): Fix logic bug in walking backwards up the filename looking for a previous directory separator. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@89029 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/diagnostic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gcc/diagnostic.c') diff --git a/gcc/diagnostic.c b/gcc/diagnostic.c index 0705c638600..c25c0ec5472 100644 --- a/gcc/diagnostic.c +++ b/gcc/diagnostic.c @@ -366,7 +366,7 @@ trim_filename (const char *name) p++, q++; /* Now go backwards until the previous directory separator. */ - while (p > name && IS_DIR_SEPARATOR (p[-1])) + while (p > name && !IS_DIR_SEPARATOR (p[-1])) p--; return p; -- cgit v1.2.1