1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-16 20:59:02 +00:00

Add some missing noreturn and format attributes.

This commit is contained in:
david
2013-02-22 00:45:55 +00:00
parent 658b8648c6
commit 129d804d15
2 changed files with 9 additions and 3 deletions

View File

@@ -98,7 +98,9 @@
#include "nbase.h" #include "nbase.h"
#include <stdio.h> #include <stdio.h>
static void fatal(char *fmt, ...) __attribute__ ((format(printf, 1, 2))); static void fatal(char *fmt, ...)
__attribute__ ((noreturn))
__attribute__ ((format (printf, 1, 2)));
static void fatal(char *fmt, ...) { static void fatal(char *fmt, ...) {
va_list ap; va_list ap;

View File

@@ -75,9 +75,13 @@
#include <unistd.h> #include <unistd.h>
#endif #endif
void fatal(char *fmt, ...) __attribute__((noreturn)); void fatal(char *fmt, ...)
__attribute__ ((noreturn))
__attribute__ ((format (printf, 1, 2)));
void pfatal(char *fmt, ...) __attribute__((noreturn)); void pfatal(char *fmt, ...)
__attribute__ ((noreturn))
__attribute__ ((format (printf, 1, 2)));
void gh_perror(char *err, ...); void gh_perror(char *err, ...);