public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc] elf: Fix use-after-free in ldconfig [BZ #26779]
@ 2022-01-26  2:58 Martin Sebor
  0 siblings, 0 replies; only message in thread
From: Martin Sebor @ 2022-01-26  2:58 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=03ad86880f68f498ee04e9ea84cd4f0d14473970

commit 03ad86880f68f498ee04e9ea84cd4f0d14473970
Author: Martin Sebor <msebor@redhat.com>
Date:   Tue Jan 25 17:37:56 2022 -0700

    elf: Fix use-after-free in ldconfig [BZ #26779]
    
    Reviewed-by: Carlos O'Donell <carlos@redhat.com>

Diff:
---
 elf/ldconfig.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/elf/ldconfig.c b/elf/ldconfig.c
index d14633f5ec..57bb95ebc3 100644
--- a/elf/ldconfig.c
+++ b/elf/ldconfig.c
@@ -735,9 +735,9 @@ manual_link (char *library)
   create_links (real_path, path, libname, soname);
   free (soname);
 out:
-  free (path);
   if (path != real_path)
     free (real_path);
+  free (path);
 }


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-01-26  2:58 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-26  2:58 [glibc] elf: Fix use-after-free in ldconfig [BZ #26779] Martin Sebor

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).