]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
PR28284 cont'd, ->winning_headers reset at start of new query
authorFrank Ch. Eigler <fche@redhat.com>
Thu, 8 Sep 2022 13:47:45 +0000 (09:47 -0400)
committerFrank Ch. Eigler <fche@redhat.com>
Thu, 8 Sep 2022 13:47:45 +0000 (09:47 -0400)
Mark noted we need to ditch the last client ->winning_headers along
with the last ->url.

Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
debuginfod/ChangeLog
debuginfod/debuginfod-client.c

index 77136698d4ccd8228a1a31be2e5ac29769dd3e07..680720ff87e8a83e8e04717f4cd296418710d0fb 100644 (file)
@@ -1,3 +1,8 @@
+2022-09-08  Frank Ch. Eigler  <fche@redhat.com>
+
+       * debuginfod-client.c (debuginfod_query_server): Clear
+       ->winning_headers along with ->url at the start of any new query.
+
 2022-09-08  Martin Liska  <mliska@suse.cz>
 
        * debuginfod-client.c (debuginfod_get_headers): Add to DUMMY_LIBDEBUGINFOD.
index 272a6a7a007f0c67ab220c58cfe76e72da06fe11..5e5c140ab2057d12d79bc24d6930be48b2b65693 100644 (file)
@@ -588,9 +588,11 @@ debuginfod_query_server (debuginfod_client *c,
       goto out;
     }
 
-  /* Clear the obsolete URL from a previous _find operation. */
+  /* Clear the obsolete data from a previous _find operation. */
   free (c->url);
   c->url = NULL;
+  free (c->winning_headers);
+  c->winning_headers = NULL;
 
   /* PR 27982: Add max size if DEBUGINFOD_MAXSIZE is set. */
   long maxsize = 0;