[Bug 239475] Linking libthr with -nodefaultlibs statically can cause infinite recursion

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Wed Jul 31 20:05:03 UTC 2019


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=239475

--- Comment #5 from commit-hook at freebsd.org ---
A commit references this bug:

Author: kib
Date: Wed Jul 31 20:04:40 UTC 2019
New revision: 350483
URL: https://svnweb.freebsd.org/changeset/base/350483

Log:
  Avoid conflicts with libc symbols in libthr jump table.

  In some corner cases of static linking and unexpected libraries order
  on the linker command line, libc symbol might preempt the same libthr
  symbol, in which case libthr jump table points back to libc causing
  either infinite recursion or loop.  Handle all of such symbols by
  using private libthr names for them, ensuring that the right pointers
  are installed into the table.

  In collaboration with: arichardson
  PR:   239475
  Tested by:    pho
  MFC after:    2 weeks
  Sponsored by: The FreeBSD Foundation
  Differential revision:        https://reviews.freebsd.org/D21088

Changes:
  head/lib/libthr/thread/thr_private.h

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-threads mailing list