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:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user