diff options
author | Tomasz Kramkowski <tomasz@kramkow.ski> | 2025-07-04 13:00:30 +0200 |
---|---|---|
committer | Tomasz Kramkowski <tomasz@kramkow.ski> | 2025-07-04 13:00:30 +0200 |
commit | d016176a3c5bd80f28315032e1176ab91e4fae85 (patch) | |
tree | 3e2d33b128d486b560669a362c2aabd618ffaa67 /src | |
parent | 37cec514b40b7f1243f98de4e5bb17de04754b0a (diff) | |
download | mqttr-d016176a3c5bd80f28315032e1176ab91e4fae85.tar.gz mqttr-d016176a3c5bd80f28315032e1176ab91e4fae85.tar.xz mqttr-d016176a3c5bd80f28315032e1176ab91e4fae85.zip |
Use write_all instead of write for the message
Diffstat (limited to 'src')
-rw-r--r-- | src/main.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs index 84ee406..edbfa1d 100644 --- a/src/main.rs +++ b/src/main.rs @@ -26,7 +26,7 @@ async fn run(program: &[String], message: &Publish) -> anyhow::Result<()> { } let mut proc = command.stdin(Stdio::piped()).spawn()?; let mut stdin = proc.stdin.take().context("No stdin")?; - stdin.write(&message.payload).await?; + stdin.write_all(&message.payload).await?; drop(stdin); println!("{}", proc.wait().await?); Ok(()) |