]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
test/crimson/test_socket: complete write-side errors in test_unexpected_down() 55751/head
authorYingxin Cheng <yingxin.cheng@intel.com>
Mon, 26 Feb 2024 06:17:48 +0000 (14:17 +0800)
committerYingxin Cheng <yingxin.cheng@intel.com>
Mon, 26 Feb 2024 06:17:48 +0000 (14:17 +0800)
Related: https://tracker.ceph.com/issues/64457
Signed-off-by: Yingxin Cheng <yingxin.cheng@intel.com>
src/test/crimson/test_socket.cc

index 8a13fb77ec7fd251ce7b7a949e5d26e67dc8e799..99c8aee84f7702eed1171e2747bdfd59d1ad89ac 100644 (file)
@@ -451,8 +451,11 @@ future<> test_unexpected_down(bool is_fixed_cpu) {
       return Connection::dispatch_rw_bounded(cs, 128, true
         ).handle_exception_type([](const std::system_error& e) {
         logger().error("test_unexpected_down(): client get error {}", e);
+        // union of errors from both read and write
+        // also see dispatch_write_unbounded() and dispatch_read_unbounded()
         ceph_assert(e.code() == error::read_eof ||
-                   e.code() == std::errc::connection_reset);
+                   e.code() == std::errc::connection_reset ||
+                    e.code() == std::errc::broken_pipe);
       });
     },
     [](auto ss) { return Connection::dispatch_rw_unbounded(ss); }