From 65515a052a0a3c5030031eb7971fc9194078269d Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Wed, 18 Jan 2006 19:48:53 +0000 Subject: 2006-01-18 Jakub Jelinek * elf/dl-deps.c (_dl_map_object_deps): In case of failure also make a copy of objname string. --- elf/dl-deps.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/elf/dl-deps.c b/elf/dl-deps.c index a73e21db7b..fd3b5243fd 100644 --- a/elf/dl-deps.c +++ b/elf/dl-deps.c @@ -247,6 +247,7 @@ _dl_map_object_deps (struct link_map *map, if (__builtin_expect (errstring != NULL, 0)) { char *new_errstring = strdupa (errstring); + objname = strdupa (objname); if (malloced) free ((char *) errstring); errstring = new_errstring; @@ -337,6 +338,7 @@ _dl_map_object_deps (struct link_map *map, if (__builtin_expect (errstring != NULL, 0)) { char *new_errstring = strdupa (errstring); + objname = strdupa (objname); if (malloced) free ((char *) errstring); errstring = new_errstring; -- cgit 1.4.1