diff options
author | bde <bde@FreeBSD.org> | 2003-12-27 13:54:02 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 2003-12-27 13:54:02 +0000 |
commit | 890b93648b786133619f78971479daff0a89b74a (patch) | |
tree | 352680ce431a914e52bc218093975486872447c0 /sbin/fsck | |
parent | e73943dcf62db248f2c939919e842d98bbf1e305 (diff) | |
download | FreeBSD-src-890b93648b786133619f78971479daff0a89b74a.zip FreeBSD-src-890b93648b786133619f78971479daff0a89b74a.tar.gz |
Use __printflike() and __dead2 instead of hard-coded gccisms.
Declare perror(). We define and use a home made version of perror(3)
that can't simply be removed (although it has the same interface as
perror(3)) since it is very different (it prints on stdout, doesn't
always print the program name, and sometimes exits). Declare it to
get a reminder of this brokenness when WARNS is increased enough.
Diffstat (limited to 'sbin/fsck')
-rw-r--r-- | sbin/fsck/fsutil.h | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/sbin/fsck/fsutil.h b/sbin/fsck/fsutil.h index 1e6db99..84e7290 100644 --- a/sbin/fsck/fsutil.h +++ b/sbin/fsck/fsutil.h @@ -31,12 +31,10 @@ * $FreeBSD$ */ -void pfatal(const char *, ...) - __attribute__((__format__(__printf__,1,2))); -void pwarn(const char *, ...) - __attribute__((__format__(__printf__,1,2))); -void panic(const char *, ...) - __attribute__((__noreturn__,__format__(__printf__,1,2))); +void perror(const char *); +void pfatal(const char *, ...) __printflike(1, 2); +void pwarn(const char *, ...) __printflike(1, 2); +void panic(const char *, ...) __dead2 __printflike(1, 2); const char *devcheck(const char *); const char *cdevname(void); void setcdevname(const char *, int); |