summaryrefslogtreecommitdiff
path: root/gcc/toplev.c
diff options
context:
space:
mode:
authorjsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4>2000-11-02 19:03:59 +0000
committerjsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4>2000-11-02 19:03:59 +0000
commit78dbff7cf909ce370d16c2b4c185ec01e419fe4c (patch)
tree79fd392a778483e0dba0d31c32d9d005dc4fdeeb /gcc/toplev.c
parenta3f30566986f897fcef17b98f722a0227de49492 (diff)
downloadgcc-78dbff7cf909ce370d16c2b4c185ec01e419fe4c.tar.gz
* collect2.c (main, write_c_file_stat), gcc.c (translate_options,
process_command, main), gcov.c (open_files, output_data), tlink.c (frob_extension, scan_linker_output), toplev.c (file_name_nondirectory): Use strchr () and strrchr () instead of index () and rindex (). cp: * dump.c (dequeue_and_dump), lex.c (interface_strcmp), method.c (build_overload_value), repo.c (open_repo_file), xref.c (open_xref_file): Use strchr () and strrchr () instead of index () and rindex (). f: * com.c (open_include_file, ffecom_open_include_): Use strchr () and strrchr () instead of index () and rindex (). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@37206 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/toplev.c')
-rw-r--r--gcc/toplev.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/toplev.c b/gcc/toplev.c
index 580b51c5088..aa8c4ba7796 100644
--- a/gcc/toplev.c
+++ b/gcc/toplev.c
@@ -1717,9 +1717,9 @@ char *
file_name_nondirectory (x)
const char *x;
{
- char *tmp = (char *) rindex (x, '/');
+ char *tmp = (char *) strrchr (x, '/');
if (DIR_SEPARATOR != '/' && ! tmp)
- tmp = (char *) rindex (x, DIR_SEPARATOR);
+ tmp = (char *) strrchr (x, DIR_SEPARATOR);
if (tmp)
return (char *) (tmp + 1);
else