freebsd-src/lib
John Polstra d5489b0d8f Check the count in the first word of __CTOR_LIST__ before executing
the loop that invokes the static constructors.  That makes it safe
to link c++rt0.o into any shared library, even one that does not
have any static constructors.  Formerly, doing that would cause a
bus error.  If the library has no static constructors, __CTOR_LIST__
comes out as a simple 4-byte COMMON region, and it does not have
the usual NULL word that terminates the list of constructors.  This
caused the old code to "call" a garbage address via the non-existent
entry __CTOR_LIST__[1].

The analogous code that invokes the static destructors was already safe.

This change is fully backward-compatible.

Reviewed by:	dfr@render.com (Doug Rabson)
1996-01-15 17:53:25 +00:00
..
csu/i386 Check the count in the first word of __CTOR_LIST__ before executing 1996-01-15 17:53:25 +00:00
libc Return pointer to new hash node when search inserts it (e.g. there 1996-01-13 14:25:04 +00:00
libcom_err Change install' to ${INSTALL}' so that default install flags can be 1995-08-06 12:24:38 +00:00
libcompat This commit was generated by cvs2svn to compensate for changes in r13122, 1995-12-30 19:02:48 +00:00
libcrypt Remove trailing whitespace. 1995-05-30 05:51:47 +00:00
libcurses Change install' to ${INSTALL}' so that default install flags can be 1995-08-06 12:24:38 +00:00
libdisk Update the -current sources from the 2.1 branch. 1995-12-07 10:34:59 +00:00
libedit This commit was generated by cvs2svn to compensate for changes in r13122, 1995-12-30 19:02:48 +00:00
libf2c Update to the 1995/09/20 version. Previous version was 1993/12/17. 1995-09-28 20:49:15 +00:00
libF77 recording cvs-1.6 file death 1995-12-30 19:02:48 +00:00
libforms recording cvs-1.6 file death 1995-12-30 19:02:48 +00:00
libI77 Update to the 1995/09/20 version. Previous version was 1993/12/17. 1995-09-28 20:49:15 +00:00
libipx Reviewed by: julian and jhay@mikom.csir.co.za 1995-10-26 20:31:59 +00:00
libkvm Extract the login name when doing a ps on a dead kernel. 1996-01-01 17:08:17 +00:00
libm Remove trailing whitespace. 1995-05-30 05:51:47 +00:00
libmd Add a structure definition to the MD* Contexts, so that cvs can use 1995-12-11 02:18:22 +00:00
libmytinfo recording cvs-1.6 file death 1995-12-30 19:02:48 +00:00
libncurses recording cvs-1.6 file death 1995-12-30 19:02:48 +00:00
libpam/modules Remove trailing whitespace. 1995-05-30 06:41:30 +00:00
libpcap Install source files with the -c flag, not with the optional flag ${COPY}. 1995-08-06 12:37:41 +00:00
libresolv
librpcsvc If we are going to set the OBJS target, don't add to the old target. This 1995-03-04 17:39:24 +00:00
libscsi Change install' to ${INSTALL}' so that default install flags can be 1995-08-06 12:24:38 +00:00
libskey recording cvs-1.6 file death 1995-12-30 19:02:48 +00:00
libss Install non-source files with the optional flag ${COPY}, not with the flag -c. 1995-08-06 12:41:07 +00:00
libtelnet This commit was generated by cvs2svn to compensate for changes in r13122, 1995-12-30 19:02:48 +00:00
libtermcap Change install' to ${INSTALL}' so that default install flags can be 1995-08-06 12:24:38 +00:00
libutil Bump libutil revision after recent addition of setproctitle(). 1996-01-01 08:27:41 +00:00
libxpg4 Add more stuff moved out from XPG3 1995-11-03 09:03:00 +00:00
liby
msun Undo the the changes in the previous revision (MANSRC now works right again). 1995-10-22 19:16:01 +00:00
ncurses/ncurses Install source files with the -c flag, not with the optional flag ${COPY}. 1995-08-06 12:37:41 +00:00
Makefile Removed reference to missing libmp in a comment. We have GNU MP now. 1995-11-12 19:32:24 +00:00
Makefile.inc