Skip to content

Commit

Permalink
"fix" copy command freezing (#553)
Browse files Browse the repository at this point in the history
  • Loading branch information
juliamertz authored Aug 24, 2024
1 parent 84e5c29 commit 9c47701
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions spotify_player/src/event/clipboard.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ impl ClipboardProvider for CommandProvider {
let mut child = std::process::Command::new(&self.copy_command.command)
.args(&self.copy_command.args)
.stdin(std::process::Stdio::piped())
.stdout(std::process::Stdio::piped())
.stderr(std::process::Stdio::piped())
.stdout(std::process::Stdio::null())
.stderr(std::process::Stdio::null())
.spawn()?;

if let Some(mut stdin) = child.stdin.take() {
Expand All @@ -46,7 +46,7 @@ impl ClipboardProvider for CommandProvider {
if output.status.success() {
Ok(())
} else {
anyhow::bail!("copy command failed: {}", String::from_utf8(output.stderr)?);
anyhow::bail!("copy command failed");
}
}
}
Expand Down

0 comments on commit 9c47701

Please sign in to comment.