From 4ffe328025381d22ff07974207935d1bae3786a4 Mon Sep 17 00:00:00 2001 From: Jesse Vincent Date: Mon, 16 Nov 2020 13:16:27 -0800 Subject: [PATCH] clean up a couple rm calls to better insulate against paths that start with -. while unlikely, the protection is easy --- testing/makefiles/libcommon.mk | 2 +- testing/makefiles/testcase.mk | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/testing/makefiles/libcommon.mk b/testing/makefiles/libcommon.mk index 2dbb976d..2a74ff01 100644 --- a/testing/makefiles/libcommon.mk +++ b/testing/makefiles/libcommon.mk @@ -47,4 +47,4 @@ ${OBJ_DIR}/%.o: ${top_dir}/testing/%.cpp ${H_FILES} $< clean: - rm -rf "${build_dir}" + rm -rf -- "${build_dir}" diff --git a/testing/makefiles/testcase.mk b/testing/makefiles/testcase.mk index 288724a1..c5882ca9 100644 --- a/testing/makefiles/testcase.mk +++ b/testing/makefiles/testcase.mk @@ -105,7 +105,7 @@ ${OBJ_DIR}/%.o: ${SRC_DIR}/%.cpp $< clean: - rm -f "${SRC_DIR}/generated-testcase.cpp" - rm -rf "${build_dir}" + rm -f -- "${SRC_DIR}/generated-testcase.cpp" + rm -rf -- "${build_dir}" .PHONY: clean run all build