Author: Emre Kultursay Date: 2025-04-25T16:16:53-07:00 New Revision: 6c78dedc14e7431aa0dd92b9dd8d35bed3e0ed7d
URL: https://github.com/llvm/llvm-project/commit/6c78dedc14e7431aa0dd92b9dd8d35bed3e0ed7d DIFF: https://github.com/llvm/llvm-project/commit/6c78dedc14e7431aa0dd92b9dd8d35bed3e0ed7d.diff LOG: Skip tests if socket name is longer than 107 bytes (#137405) To fix the test failures introduced in Commit 488eeb3 Added: Modified: lldb/unittests/Host/SocketTest.cpp Removed: ################################################################################ diff --git a/lldb/unittests/Host/SocketTest.cpp b/lldb/unittests/Host/SocketTest.cpp index 5bfb48b52f7e7..77366593f05f8 100644 --- a/lldb/unittests/Host/SocketTest.cpp +++ b/lldb/unittests/Host/SocketTest.cpp @@ -349,6 +349,10 @@ TEST_F(SocketTest, DomainSocketFromBoundNativeSocket) { ASSERT_FALSE(EC); llvm::sys::path::append(name, "test"); + // Skip the test if the $TMPDIR is too long to hold a domain socket. + if (name.size() > 107u) + GTEST_SKIP() << "$TMPDIR is too long to hold a domain socket"; + DomainSocket socket(true); Status error = socket.Listen(name, /*backlog=*/10); ASSERT_THAT_ERROR(error.takeError(), llvm::Succeeded()); @@ -370,6 +374,10 @@ TEST_F(SocketTest, AbstractSocketFromBoundNativeSocket) { true); llvm::sys::path::append(name, "test"); + // Skip the test if the $TMPDIR is too long to hold a domain socket. + if (name.size() > 107u) + GTEST_SKIP() << "$TMPDIR is too long to hold a domain socket"; + AbstractSocket socket; Status error = socket.Listen(name, /*backlog=*/10); ASSERT_THAT_ERROR(error.takeError(), llvm::Succeeded()); _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits