From 421055caa5d450505d0fbf6a472dace6c3f12f9e Mon Sep 17 00:00:00 2001 From: nathan Date: Thu, 29 Jul 2004 08:58:59 +0000 Subject: * gcov-io.h: Allow zero tag as EOF indicator. (gcov_is_eof): Remove. (gcov_truncate): Remove. * gcov-io.c (gcov_seek): Always SEEK_SET. * libgcov.c (gcov_exit): Don't use gcov_truncate. Write explicit EOF tag. * coverage.c (read_counts_file): Don't use gcov_is_eof. * gcov-dump.c (dump_file): Likewise. * gcov.c (read_graph_file, read_count_file): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@85291 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/coverage.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'gcc/coverage.c') diff --git a/gcc/coverage.c b/gcc/coverage.c index eb6f801982b..abaad02d11d 100644 --- a/gcc/coverage.c +++ b/gcc/coverage.c @@ -292,14 +292,12 @@ read_counts_file (void) } gcov_sync (offset, length); if ((is_error = gcov_is_error ())) - break; - } - - if (!gcov_is_eof ()) - { - error (is_error < 0 ? "`%s' has overflowed" : "`%s' is corrupted", - da_file_name); - htab_delete (counts_hash); + { + error (is_error < 0 ? "`%s' has overflowed" : "`%s' is corrupted", + da_file_name); + htab_delete (counts_hash); + break; + } } gcov_close (); -- cgit v1.2.1