projects
/
gnulib.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
gc: support HMAC-SHA256 and HMAC-SHA512.
[gnulib.git]
/
tests
/
test-raise.c
diff --git
a/tests/test-raise.c
b/tests/test-raise.c
index
38c2353
..
3c58b6b
100644
(file)
--- a/
tests/test-raise.c
+++ b/
tests/test-raise.c
@@
-1,5
+1,5
@@
/* Test raising a signal.
/* Test raising a signal.
- Copyright (C) 2011 Free Software Foundation, Inc.
+ Copyright (C) 2011
-2013
Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@
-25,7
+25,10
@@
SIGNATURE_CHECK (raise, int, (int));
#include "macros.h"
#include "macros.h"
-static void
+/* It is safe to use _Noreturn here: exit() never returns, and GCC knows that
+ exit() is a non-returning function, even on platforms where its declaration
+ in <stdlib.h> does not have the 'noreturn' attribute. */
+static _Noreturn void
handler (int sig)
{
exit (0);
handler (int sig)
{
exit (0);
@@
-36,7
+39,6
@@
main (void)
{
/* Test behaviour for invalid argument. */
ASSERT (raise (-1) != 0);
{
/* Test behaviour for invalid argument. */
ASSERT (raise (-1) != 0);
- ASSERT (raise (99) != 0);
/* Test behaviour for SIGINT. */
ASSERT (signal (SIGINT, handler) != SIG_ERR);
/* Test behaviour for SIGINT. */
ASSERT (signal (SIGINT, handler) != SIG_ERR);