panic: declare as printf-style-checked

Change-Id: I5131ac57dc53d8aec8d421a34c5ceea383404d7a
This commit is contained in:
Ben Gras 2013-02-02 00:55:35 +00:00
parent 5507a12d7c
commit 1c0da5926e
2 changed files with 3 additions and 2 deletions

View File

@ -48,7 +48,8 @@ int fkey_ctl(int req, int *fkeys, int *sfkeys);
int printf(const char *fmt, ...);
void kputc(int c);
__dead void panic(const char *fmt, ...);
__dead void panic(const char *fmt, ...)
__attribute__((__format__(__printf__,1,2)));
int getuptime(clock_t *ticks, clock_t *realtime, time_t *boottime);
int getticks(clock_t *ticks);
int tickdelay(clock_t ticks);

View File

@ -673,7 +673,7 @@ struct filp *f;
f->filp_mode = FILP_CLOSED;
f->filp_count = 0;
} else if (f->filp_count < 0) {
panic("VFS: invalid filp count: %d ino %d/%d", f->filp_count,
panic("VFS: invalid filp count: %d ino %d/%u", f->filp_count,
vp->v_dev, vp->v_inode_nr);
} else {
unlock_vnode(f->filp_vno);