]> git.ipfire.org Git - thirdparty/glibc.git/blobdiff - csu/init-first.c
Prefer https to http for gnu.org and fsf.org URLs
[thirdparty/glibc.git] / csu / init-first.c
index 0cfabbce28d88cdfc992614dc70e638e0de784f4..e0f489ee6d0e6282b7285ff28e49a74bb6b28f65 100644 (file)
@@ -1,5 +1,5 @@
 /* Initialization code run first thing by the ELF startup code.  Common version
-   Copyright (C) 1995-2012 Free Software Foundation, Inc.
+   Copyright (C) 1995-2019 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -14,7 +14,7 @@
 
    You should have received a copy of the GNU Lesser General Public
    License along with the GNU C Library; if not, see
-   <http://www.gnu.org/licenses/>.  */
+   <https://www.gnu.org/licenses/>.  */
 
 #include <ctype.h>
 #include <stdio.h>
@@ -29,7 +29,7 @@
 
 #include <ldsodefs.h>
 
-/* Set nonzero if we have to be prepared for more then one libc being
+/* Set nonzero if we have to be prepared for more than one libc being
    used in the process.  Safe assumption if initializer never runs.  */
 int __libc_multiple_libcs attribute_hidden = 1;
 
@@ -50,9 +50,6 @@ void
 attribute_hidden
 _init (int argc, char **argv, char **envp)
 {
-#endif
-#ifdef USE_NONOPTION_FLAGS
-  extern void __getopt_clean_environment (char **);
 #endif
 
   __libc_multiple_libcs = &_dl_starting_up && !_dl_starting_up;
@@ -61,11 +58,8 @@ _init (int argc, char **argv, char **envp)
   if (!__libc_multiple_libcs)
     {
       /* Set the FPU control word to the proper default value if the
-        kernel would use a different value.  (In a static program we
-        don't have this information.)  */
-#ifdef SHARED
+        kernel would use a different value.  */
       if (__fpu_control != GLRO(dl_fpu_control))
-#endif
        __setfpucw (__fpu_control);
     }
 
@@ -75,8 +69,6 @@ _init (int argc, char **argv, char **envp)
   __environ = envp;
 
 #ifndef SHARED
-  __libc_init_secure ();
-
   /* First the initialization which normally would be done by the
      dynamic linker.  */
   _dl_non_dynamic_init ();
@@ -88,11 +80,6 @@ _init (int argc, char **argv, char **envp)
 
   __init_misc (argc, argv, envp);
 
-#ifdef USE_NONOPTION_FLAGS
-  /* This is a hack to make the special getopt in GNU libc working.  */
-  __getopt_clean_environment (envp);
-#endif
-
   /* Initialize ctype data.  */
   __ctype_init ();