Skip to content

fix: correct test fd and convert HostSocket to struct - #58

Merged
danbugs merged 1 commit into
mainfrom
fix/test-and-hostsocket
May 17, 2026
Merged

fix: correct test fd and convert HostSocket to struct#58
danbugs merged 1 commit into
mainfrom
fix/test-and-hostsocket

Conversation

@danbugs

@danbugs danbugs commented May 17, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Fixes net_bind_denied_without_listen_ports test to use the actual fd returned by net_socket instead of hardcoded fd:0 — the test previously passed only because the permission check fires before fd lookup
  • Converts HostSocket from a single-variant enum to a plain struct with named fields, simplifying all match sites to direct field access

Test plan

  • cargo test --lib passes (51 tests)
  • cargo clippy --lib clean
  • cargo fmt clean

Signed-off-by: danbugs <danilochiarlone@gmail.com>

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Linux Benchmarks

Details
Benchmark suite Current: 65babe2 Previous: 86d2609 Ratio
hello_world (median) 20 ms 20 ms 1
pandas (median) 100 ms 110 ms 0.91
density (per VM) 7 MB 7 MB 1
snapshot (disk) 385 MiB 385 MiB 1

This comment was automatically generated by workflow using github-action-benchmark.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Windows Benchmarks

Details
Benchmark suite Current: 65babe2 Previous: 86d2609 Ratio
hello_world (median) 260 ms 245 ms 1.06
pandas (median) 883 ms 725 ms 1.22
density (per VM) 6 MB 6 MB 1
snapshot (disk) 392 MiB 392 MiB 1

This comment was automatically generated by workflow using github-action-benchmark.

@danbugs
danbugs enabled auto-merge (squash) May 17, 2026 06:03
@danbugs
danbugs merged commit ee4453d into main May 17, 2026
79 checks passed
@danbugs
danbugs deleted the fix/test-and-hostsocket branch May 17, 2026 06:03
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