fix: use TCP instead of Unix socket on Windows in dashboard relay (#1038)

`relay_command_to_daemon` in stream.rs used `tokio::net::UnixStream`
unconditionally, which doesn't compile on Windows. Add platform-
conditional code matching the existing pattern in daemon.rs and
connection.rs: Unix sockets on unix, TCP on Windows.
This commit is contained in:
Chris Tate
2026-03-26 13:36:22 -07:00
committed by GitHub
parent f9174513c2
commit 995a47fdb0
2 changed files with 22 additions and 10 deletions
+1 -1
View File
@@ -144,7 +144,7 @@ fn get_port_path(session: &str) -> PathBuf {
}
#[cfg(windows)]
fn get_port_for_session(session: &str) -> u16 {
pub fn get_port_for_session(session: &str) -> u16 {
let mut hash: i32 = 0;
for c in session.chars() {
hash = ((hash << 5).wrapping_sub(hash)).wrapping_add(c as i32);