public inbox for elfutils@sourceware.org
 help / color / mirror / Atom feed
From: Mark Wielaard <mark@klomp.org>
To: Noah Sanci <nsanci@redhat.com>, elfutils-devel@sourceware.org
Subject: Re: [Bug debuginfod/28034] %-escape url characters
Date: Thu, 22 Jul 2021 14:29:01 +0200	[thread overview]
Message-ID: <67181ab24c7a1904b07a50db7d3d6b46425203fa.camel@klomp.org> (raw)
In-Reply-To: <CAJXA7qgv50qXqD_YmkxkbO+OxZ93jES9B3Syuo6_FZ_CL_QiZA@mail.gmail.com>

Hi Noah,

On Wed, 2021-07-21 at 15:44 -0400, Noah Sanci via Elfutils-devel wrote:
> Here is a quick error fix.

Thanks, looks good. Failure results should indeed be negative.
For the record the actual fix was:

diff --git a/debuginfod/debuginfod-client.c b/debuginfod/debuginfod-client.c
index 64936acd..26ba1891 100644
--- a/debuginfod/debuginfod-client.c
+++ b/debuginfod/debuginfod-client.c
@@ -831,14 +831,14 @@ debuginfod_query_server (debuginfod_client *c,
       else
         slashbuildid = "/buildid";
 
-      if (filename)/* must start with / */
+      if (filename) /* must start with / */
         {
           /* PR28034 escape characters in completed url to %hh format. */
           char *escaped_string;
           escaped_string = curl_easy_escape(data[i].handle, filename, 0);
           if (!escaped_string)
             {
-              rc = ENOMEM;
+              rc = -ENOMEM;
               goto out1;
             }
           snprintf(data[i].url, PATH_MAX, "%s%s/%s/%s%s", server_url,

Pushed this version.

Thanks,

Mark

  reply	other threads:[~2021-07-22 12:29 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-19 14:53 Noah Sanci
2021-07-20 17:50 ` Mark Wielaard
2021-07-20 18:13   ` Frank Ch. Eigler
2021-07-20 19:08   ` Mark Wielaard
2021-07-21 18:18   ` Noah Sanci
2021-07-21 19:44     ` Noah Sanci
2021-07-22 12:29       ` Mark Wielaard [this message]
2021-07-22 12:28     ` Mark Wielaard

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=67181ab24c7a1904b07a50db7d3d6b46425203fa.camel@klomp.org \
    --to=mark@klomp.org \
    --cc=elfutils-devel@sourceware.org \
    --cc=nsanci@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).