]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
* debug/chk_fail.c (__chk_fail): Add a while (1) loop around
authorJakub Jelinek <jakub@redhat.com>
Fri, 11 Feb 2005 15:06:18 +0000 (15:06 +0000)
committerJakub Jelinek <jakub@redhat.com>
Fri, 11 Feb 2005 15:06:18 +0000 (15:06 +0000)
__libc_message to kill GCC warning about noreturn function returning.

ChangeLog
debug/chk_fail.c

index b71840f9fdefd0273a2eb5016d82a8770b3b0df5..be37c4732a610f45c08e386317baef74effa04c4 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2005-02-11  Jakub Jelinek  <jakub@redhat.com>
 
+       * debug/chk_fail.c (__chk_fail): Add a while (1) loop around
+       __libc_message to kill GCC warning about noreturn function returning.
+
        * elf/rtld.c (_dl_start): Set bootstrap_map.l_relocated even
        for already prelinked ld.so.
 
index 29df08b9cae9c24674f49dd557624bdfb7a4708a..6921ca4686bd112bc4cce282afea6800c9e4e84c 100644 (file)
@@ -26,7 +26,9 @@ void
 __attribute__ ((noreturn))
 __chk_fail (void)
 {
-  __libc_message (1, "*** buffer overflow detected ***: %s terminated\n",
-                 __libc_argv[0] ?: "<unknown>");
+  /* The loop is added only to keep gcc happy.  */
+  while (1)
+    __libc_message (1, "*** buffer overflow detected ***: %s terminated\n",
+                   __libc_argv[0] ?: "<unknown>");
 }
 libc_hidden_def (__chk_fail)