]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
PR 34275 double free in ctf_link_deduplicating_per_cu
authorxuqing yang <rigelyoung@icloud.com>
Wed, 10 Jun 2026 14:12:05 +0000 (14:12 +0000)
committerAlan Modra <amodra@gmail.com>
Fri, 3 Jul 2026 23:53:00 +0000 (09:23 +0930)
* ctf-link.c (ctf_link_deduplicating_per_cu): Don't call
ctf_next_destroy twice on error path.

libctf/ctf-link.c

index 9fdd39fdb9514f8cf7c33ef8f02c1d04cfbd7c96..c6d0a86f4b75e9bf5cf08e57ebeee9a6f972b18f 100644 (file)
@@ -1187,10 +1187,7 @@ ctf_link_deduplicating_per_cu (ctf_dict_t *fp)
 
       if ((inputs = ctf_link_deduplicating_open_inputs (fp, in, ninputs,
                                                        &parents)) == NULL)
-       {
-         ctf_next_destroy (i);
-         goto err_open_inputs;
-       }
+       goto err_open_inputs;
 
       if ((out = ctf_create (&err)) == NULL)
        {