Skip to content

Commit

Permalink
test: common: Actually use different AF_UNIX sockets for newTempAddress
Browse files Browse the repository at this point in the history
Previously, we were reusing SocketTestBase.socketFile(), which may
result in unexpected errors due to race conditions.

Create new AF_UNIX temp addresses using
AFUNIXSocketAddress.ofNewTempFile() instead.
  • Loading branch information
kohlschuetter committed Feb 14, 2024
1 parent c2602d3 commit 5c1ec41
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ private AFUNIXAddressSpecifics() {

@Override
public AFSocketAddress newTempAddress() throws IOException {
return AFUNIXSocketAddress.of(SocketTestBase.socketFile());
return AFUNIXSocketAddress.ofNewTempFile();
}

@Override
Expand Down

0 comments on commit 5c1ec41

Please sign in to comment.