Guard two constants the Windows target leaves unused

secrets.rs names the keyring service and desktop_client.rs the socket
timeout, and every use of both sits under a cfg that a Windows build
does not satisfy — the placeholder secret store has nothing to file
under, and the Nextcloud client's named pipe is not opened yet. The
first cross-compile reported both as dead code, which is a failed
clippy job the moment the Windows leg runs with -D warnings. Guarded
by the same cfgs as their users, with the reason beside each.
This commit is contained in:
2026-09-12 00:54:10 +02:00
parent b718c70b11
commit 0a2c49dd10
3 changed files with 11 additions and 2 deletions
@@ -19,11 +19,16 @@ use std::io::{BufRead, BufReader, Write};
#[cfg(unix)]
use std::os::unix::net::UnixStream;
use std::path::{Path, PathBuf};
#[cfg(unix)]
use std::time::Duration;
use dr_sync::RemoteError;
/// How long to wait for the client to acknowledge a command.
///
/// Only the socket path waits; on Windows the client speaks over a named pipe
/// this module does not yet open, so there is nothing to time.
#[cfg(unix)]
const TIMEOUT: Duration = Duration::from_secs(5);
/// A connection to a running desktop client.