This is an automated email from the ASF dual-hosted git repository.
jiashunzhu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/brpc.git
The following commit(s) were added to refs/heads/master by this push:
new 0c7f178a Fix deleting non existing file in test/iobuf_unittest.cpp
when writing to dev_null(#2346)
0c7f178a is described below
commit 0c7f178a38361855c361de2882cbf39a725e684f
Author: [email protected]
<[email protected]>
AuthorDate: Mon Aug 7 00:00:52 2023 +0800
Fix deleting non existing file in test/iobuf_unittest.cpp when writing to
dev_null(#2346)
---
test/iobuf_unittest.cpp | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/test/iobuf_unittest.cpp b/test/iobuf_unittest.cpp
index 5add0104..e7a6e10d 100644
--- a/test/iobuf_unittest.cpp
+++ b/test/iobuf_unittest.cpp
@@ -1027,7 +1027,9 @@ TEST_F(IOBufTest, append_store_append_cut) {
if (!write_to_dev_null) {
ASSERT_EQ(0, system(cmd));
}
- remove(name);
+ if (!write_to_dev_null) {
+ remove(name);
+ }
}
for (size_t i = 0; i < ARRAY_SIZE(w); ++i) {
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]