mirror of
https://github.com/nmap/nmap.git
synced 2025-12-06 04:31:29 +00:00
Fix MSVC compiler noreturn related warnings and add extra
safety asserts to the functions that do not return on all control paths.
This commit is contained in:
@@ -121,11 +121,18 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef WIN32
|
||||
__declspec(noreturn)
|
||||
#endif
|
||||
void fatal(const char *fmt, ...)
|
||||
__attribute__ ((noreturn))
|
||||
__attribute__ ((format (printf, 1, 2)));
|
||||
void error(const char *fmt, ...)
|
||||
__attribute__ ((format (printf, 1, 2)));
|
||||
|
||||
#ifdef WIN32
|
||||
__declspec(noreturn)
|
||||
#endif
|
||||
void pfatal(const char *err, ...)
|
||||
__attribute__ ((noreturn))
|
||||
__attribute__ ((format (printf, 1, 2)));
|
||||
|
||||
Reference in New Issue
Block a user