]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
PR422261 platform selection fails for unqualified client name
authorMark Wielaard <mark@klomp.org>
Thu, 4 Feb 2021 15:14:00 +0000 (16:14 +0100)
committerMark Wielaard <mark@klomp.org>
Thu, 4 Feb 2021 15:44:24 +0000 (16:44 +0100)
Bug introduced with commit f15beea76
"Fix memory leak in launcher-linux.c"

Need to try opening the actual 'client' path, not just the 'clientname'
file name.

Reported-by: Michael Wojcik <michael.wojcik@microfocus.com>
https://bugs.kde.org/show_bug.cgi?id=422261

NEWS
coregrind/launcher-linux.c

diff --git a/NEWS b/NEWS
index e196e8fecdfeb1f2437a0b4ce973e2517d55f00a..2d0409157b5532b40272b149299c7fa44f9f1d25 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -63,6 +63,7 @@ n-i-bz  helgrind: If hg_cli__realloc fails, return NULL.
         (actually affected all x86 and nanomips regardless of host bitness)
 415293  Incorrect call-graph tracking due to new _dl_runtime_resolve_xsave*
 422174  unhandled instruction bytes: 0x48 0xE9 (REX prefixed JMP instruction)
+422261  platform selection fails for unqualified client name
 422623  epoll_ctl warns for uninitialized padding on non-amd64 64bit arches
 423021  PPC:  Add missing ISA 3.0 documentation link and HWCAPS test.
 424298  amd64: Implement RDSEED
index 7a1224877e4dda3ac1b87bfe64d5c85a5bdfe06c..bc95e3c115340691c6591cafe6f1b3ae6708f984 100644 (file)
@@ -158,7 +158,7 @@ static const char *select_platform(const char *clientname)
    if (strcmp (client, clientname) != 0)
       VG_(debugLog)(2, "launcher", "selecting platform for '%s'\n", client);
 
-   if ((fd = open(clientname, O_RDONLY)) < 0) {
+   if ((fd = open(client, O_RDONLY)) < 0) {
      return_null:
       free (client);
       return NULL;