summaryrefslogtreecommitdiff
path: root/gcc/coverage.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/coverage.c')
-rw-r--r--gcc/coverage.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gcc/coverage.c b/gcc/coverage.c
index 0a949c3a9f7..53e379b3295 100644
--- a/gcc/coverage.c
+++ b/gcc/coverage.c
@@ -731,6 +731,18 @@ coverage_end_function (unsigned lineno_checksum, unsigned cfg_checksum)
}
}
+/* Remove coverage file if opened. */
+
+void
+coverage_remove_note_file (void)
+{
+ if (bbg_file_name)
+ {
+ gcov_close ();
+ unlink (bbg_file_name);
+ }
+}
+
/* Build a coverage variable of TYPE for function FN_DECL. If COUNTER
>= 0 it is a counter array, otherwise it is the function structure. */