all lists on lists.proxmox.com
 help / color / mirror / Atom feed
From: Thomas Lamprecht <t.lamprecht@proxmox.com>
To: Proxmox Backup Server development discussion
	<pbs-devel@lists.proxmox.com>,
	Lukas Wagner <l.wagner@proxmox.com>
Subject: Re: [pbs-devel] [PATCH proxmox-backup] system-report: fix 'unused Result' warning
Date: Fri, 24 Nov 2023 12:22:42 +0100	[thread overview]
Message-ID: <9a10e9a7-7541-4fa6-aca7-86c09bd24183@proxmox.com> (raw)
In-Reply-To: <20231124082819.46802-1-l.wagner@proxmox.com>

Am 24/11/2023 um 09:28 schrieb Lukas Wagner:
> Signed-off-by: Lukas Wagner <l.wagner@proxmox.com>
> ---
>  src/server/report.rs | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/src/server/report.rs b/src/server/report.rs
> index 703daa71..ea31cbf9 100644
> --- a/src/server/report.rs
> +++ b/src/server/report.rs
> @@ -162,7 +162,11 @@ fn get_command_output(exe: &str, args: &Vec<&str>) -> String {
>                  .trim_end()
>                  .to_string();
>              if !stderr.is_empty() {
> -                writeln!(out, "\n```\nSTDERR:\n```\n{stderr}");
> +                // Does not really make sense to append any error
> +                // to 'out' - since that write would probably fail
> +                // too... also, AFAICT this should never fail -
> +                // in case of OOM, Rust will simply abort
> +                let _ = writeln!(out, "\n```\nSTDERR:\n```\n{stderr}");
>              }
>              out
>          }

yikes, I actually wanted to fix that before pushing those changes out, meh.

Thanks for sending a patch, I also noticed the warning again when testing
Stefan Lendls prune job series and pushed a fix directly (without comment
as we do that quite a few times already)




      reply	other threads:[~2023-11-24 11:22 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-24  8:28 Lukas Wagner
2023-11-24 11:22 ` Thomas Lamprecht [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9a10e9a7-7541-4fa6-aca7-86c09bd24183@proxmox.com \
    --to=t.lamprecht@proxmox.com \
    --cc=l.wagner@proxmox.com \
    --cc=pbs-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal