Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🚩 zb: Disable UDS support on Windows for tokio #585

Merged
merged 1 commit into from
Feb 11, 2024

Conversation

zeenix
Copy link
Contributor

@zeenix zeenix commented Feb 11, 2024

Since tokio currently does not support Unix domain sockets on Windows, there is no reason to enable UDS support on Windows+tokio. This also fixes a build warning against rust nightly:

error: field `0` is never read
  --> zbus\src\connection\builder.rs:45:16
   |
45 |     UnixStream(UnixStream),
   |     ---------- ^^^^^^^^^^
   |     |
   |     field in this variant
   |
   = note: `-D dead-code` implied by `-D warnings`
   = help: to override `-D warnings` add `#[allow(dead_code)]`
help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field
   |
45 |     UnixStream(()),
   |                ~~

Since tokio currently [does not support Unix domain sockets on
Windows][tuds], there is no reason to enable UDS support on Windows+tokio.
This also fixes a build warning against rust nightly:

```rust
error: field `0` is never read
  --> zbus\src\connection\builder.rs:45:16
   |
45 |     UnixStream(UnixStream),
   |     ---------- ^^^^^^^^^^
   |     |
   |     field in this variant
   |
   = note: `-D dead-code` implied by `-D warnings`
   = help: to override `-D warnings` add `#[allow(dead_code)]`
help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field
   |
45 |     UnixStream(()),
   |                ~~
```

[tuds]: tokio-rs/tokio#2201
@zeenix zeenix merged commit 4d13c62 into dbus2:main Feb 11, 2024
7 checks passed
@zeenix zeenix deleted the disable-uds-on-windows+tokio branch February 11, 2024 22:20
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