]> Savannah Git Hosting - gnulib.git/commitdiff
xalloc: Fix compilation error in C++ mode on FreeBSD 12.
authorBruno Haible <bruno@clisp.org>
Sun, 2 Feb 2020 17:16:55 +0000 (18:16 +0100)
committerBruno Haible <bruno@clisp.org>
Sun, 2 Feb 2020 17:16:55 +0000 (18:16 +0100)
* lib/xalloc.h (xalloc_die): Comment out 'extern' keyword before
'_Noreturn'.
* lib/sigpipe-die.h (sigpipe_die): Likewise.

ChangeLog
lib/sigpipe-die.h
lib/xalloc.h

index 86f8626d680bff8c0c20919e983700b261b0ab0a..19238837cad16a73ed084bfa6e207408691849b5 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2020-02-02  Bruno Haible  <bruno@clisp.org>
+
+       xalloc: Fix compilation error in C++ mode on FreeBSD 12.
+       * lib/xalloc.h (xalloc_die): Comment out 'extern' keyword before
+       '_Noreturn'.
+       * lib/sigpipe-die.h (sigpipe_die): Likewise.
+
 2020-02-02  Pádraig Brady  <P@draigBrady.com>
 
        read-file: reduce max size from SIZE_MAX to PTRDIFF_MAX
index dcb9a4a78e09f147111b6dac1616d82ac8dd0f90..7fcde8cfc89aec151ee27232152477ce72db7cd1 100644 (file)
@@ -48,7 +48,7 @@ extern "C" {
 
 /* Emit an error message indicating a SIGPIPE signal, and terminate the
    process with an error code.  */
-extern _Noreturn void sigpipe_die (void);
+/*extern*/ _Noreturn void sigpipe_die (void);
 
 /* Install a SIGPIPE handler that invokes PREPARE_DIE and then emits an
    error message and exits.  PREPARE_DIE may be NULL, meaning a no-op.  */
index 9563b0bc926803774bf017a5cf6e3bc16db992bc..19c64acb4168436124c88d292c7dd915884bf34b 100644 (file)
@@ -48,7 +48,7 @@ extern "C" {
    or by using gnulib's xalloc-die module.  This is the
    function to call when one wants the program to die because of a
    memory allocation failure.  */
-extern _Noreturn void xalloc_die (void);
+/*extern*/ _Noreturn void xalloc_die (void);
 
 void *xmalloc (size_t s)
       _GL_ATTRIBUTE_MALLOC _GL_ATTRIBUTE_ALLOC_SIZE ((1));