]> git.ipfire.org Git - thirdparty/glibc.git/commit
nptl: Fix invalid Systemtap probe in pthread_join [BZ #24211]
authorFlorian Weimer <fweimer@redhat.com>
Fri, 15 Feb 2019 18:09:00 +0000 (19:09 +0100)
committerFlorian Weimer <fweimer@redhat.com>
Fri, 15 Feb 2019 18:09:00 +0000 (19:09 +0100)
commitbc10e22c90e42613bd5dafb77b80a9ea1759dd1b
tree6a4ad2ab7ea72292e1733e7a4ef7f70eb4fc8c09
parent8a11f97062ec7f1a2fed4aefa36c7bebecf87181
nptl: Fix invalid Systemtap probe in pthread_join [BZ #24211]

After commit f1ac7455831546e5dca0ed98fe8af2686fae7ce6 ("arm: Use "nr"
constraint for Systemtap probes [BZ #24164]"), we load pd->result into
a register in the probe below:

      /* Free the TCB.  */
      __free_tcb (pd);
    }
  else
    pd->joinid = NULL;

  LIBC_PROBE (pthread_join_ret, 3, threadid, result, pd->result);

However, at this point, the thread descriptor has been freed.  If the
thread stack does not fit into the thread stack cache, the memory will
have been unmapped, and the program will crash in the probe.
ChangeLog
nptl/pthread_join_common.c