comparison libtomcrypt/src/misc/crypt/crypt_argchk.c @ 1090:93e1a0eb40ef

Uses abort() instead of raising a SIGABRT signal [-Werror] error: ‘noreturn’ function does return [-Werror] abort() is a noreturn function while raise() is not. And because crypt_argchk() is flagged as __attribute__(noreturn), abort() appears to be a better condidate. This compilation warning has probably been introduced by commit 1809f741cba865b03d4db5c4ba8c41364a55d6bc.
author Gaël PORTAY <gael.portay@gmail.com>
date Sat, 02 May 2015 11:26:22 +0200
parents 0cbe8f6dbf9e
children f849a5ca2efc
comparison
equal deleted inserted replaced
1089:d144a6bece53 1090:93e1a0eb40ef
19 #if (ARGTYPE == 0) 19 #if (ARGTYPE == 0)
20 void crypt_argchk(char *v, char *s, int d) 20 void crypt_argchk(char *v, char *s, int d)
21 { 21 {
22 fprintf(stderr, "LTC_ARGCHK '%s' failure on line %d of file %s\n", 22 fprintf(stderr, "LTC_ARGCHK '%s' failure on line %d of file %s\n",
23 v, d, s); 23 v, d, s);
24 (void)raise(SIGABRT); 24 abort();
25 } 25 }
26 #endif 26 #endif
27 27
28 /* $Source: /cvs/libtom/libtomcrypt/src/misc/crypt/crypt_argchk.c,v $ */ 28 /* $Source: /cvs/libtom/libtomcrypt/src/misc/crypt/crypt_argchk.c,v $ */
29 /* $Revision: 1.4 $ */ 29 /* $Revision: 1.4 $ */