Skip to content

Conversation

@wokron
Copy link
Owner

@wokron wokron commented Feb 10, 2026

No description provided.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new io_uring “command” wrapper for getsockname to the Condy async operations layer, along with tests and documentation updates.

Changes:

  • Add condy::async_cmd_getsockname() wrapper (guarded for liburing >= 2.13).
  • Add basic and fixed-fd test cases for async_cmd_getsockname().
  • Update ops documentation to include async_nop128() and async_cmd_getsockname().

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
include/condy/async_operations.hpp Introduces the new async_cmd_getsockname() wrapper using the existing op-awaiter pattern.
tests/test_async_operations.4.cpp Adds new test coverage for async_cmd_getsockname() and fixes SO_REUSEADDR option value initialization in existing tests.
docs/ops.md Documents the newly exposed operations in the operation list.
Comments suppressed due to low confidence (1)

tests/test_async_operations.4.cpp:302

  • In the "cmd_sock - fixed fd" test, listen_fd is never closed after sync_wait, unlike the other socket tests in this file. This can leak file descriptors across the test suite; add a close(listen_fd) (or a RAII/defer cleanup) after the coroutine completes.
        int val = 1;
        r = co_await condy::async_cmd_sock(SOCKET_URING_OP_SETSOCKOPT,
                                           condy::fixed(0), SOL_SOCKET,
                                           SO_REUSEADDR, &val, sizeof(val));
        REQUIRE(r == 0);

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@wokron wokron force-pushed the support-getsockname branch from 9741142 to 82cd717 Compare February 10, 2026 11:37
@wokron wokron merged commit f7c40a7 into master Feb 10, 2026
11 checks passed
@wokron wokron deleted the support-getsockname branch February 10, 2026 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant