aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/backends/zenity.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backends/zenity.rs b/src/backends/zenity.rs
index 0730c64..85206b3 100644
--- a/src/backends/zenity.rs
+++ b/src/backends/zenity.rs
@@ -128,8 +128,8 @@ fn get_choice(status: process::ExitStatus) -> Result<Choice> {
fn get_stdout(output: process::Output) -> Result<Option<String>> {
if output.status.success() {
- String::from_utf8(output.stderr)
- .map(|s| Some(s))
+ String::from_utf8(output.stdout)
+ .map(|s| Some(s.trim_end_matches('\n').to_string()))
.map_err(|err| Error::from(err))
} else {
if let Some(code) = output.status.code() {