aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plugins/cover.mk3
1 files changed, 1 insertions, 2 deletions
diff --git a/plugins/cover.mk b/plugins/cover.mk
index a14b992..60809a3 100644
--- a/plugins/cover.mk
+++ b/plugins/cover.mk
@@ -81,8 +81,7 @@ ifneq ($(COVER_REPORT_DIR),)
cover-report-clean:
$(gen_verbose) rm -rf $(COVER_REPORT_DIR)
- # Remove the COVER_DATA_DIR only if it is empty.
- -$(verbose) rmdir $(COVER_DATA_DIR)
+ $(if $(shell ls -A $(COVER_DATA_DIR)/),,$(verbose) rmdir $(COVER_DATA_DIR))
ifeq ($(COVERDATA),)
cover-report: