From 9f68fe4e9a1a745ce8a8e7e817975adb5c77e8d9 Mon Sep 17 00:00:00 2001 From: Antony Polukhin Date: Fri, 17 Mar 2017 07:25:18 +0300 Subject: [PATCH] Make test more tolerant to filesystem faults --- example/terminate_handler.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/example/terminate_handler.cpp b/example/terminate_handler.cpp index 6011a2c..ad222a6 100644 --- a/example/terminate_handler.cpp +++ b/example/terminate_handler.cpp @@ -91,7 +91,8 @@ inline void copy_and_run(const char* exec_name, char param, bool not_null) { const int ret = std::system(command_args.string().c_str()); std::cout << "End Running with param " << param << "; ret code is " << ret << std::endl; - boost::filesystem::remove(command); + boost::system::error_code ignore; + boost::filesystem::remove(command, ignore); if (not_null && !ret) { std::exit(97); } else if (!not_null && ret) {