public inbox for cluster-cvs@sourceware.org
help / color / mirror / Atom feed
* cluster: STABLE3 - libgfs2: format checking for printf-like functions
@ 2009-02-19 10:09 Fabio M. Di Nitto
0 siblings, 0 replies; only message in thread
From: Fabio M. Di Nitto @ 2009-02-19 10:09 UTC (permalink / raw)
To: cluster-cvs-relay
Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=ee684e0bdd66cc175e7eb774912d171905b58df0
Commit: ee684e0bdd66cc175e7eb774912d171905b58df0
Parent: af56981cec36a6d4f813e192821979f5e7f91b68
Author: Steven Whitehouse <swhiteho@redhat.com>
AuthorDate: Mon Jan 26 09:08:37 2009 +0000
Committer: Fabio M. Di Nitto <fdinitto@redhat.com>
CommitterDate: Thu Feb 19 10:59:54 2009 +0100
libgfs2: format checking for printf-like functions
It appears that there are a lot of bugs in fsck's format strings.
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
---
gfs2/libgfs2/libgfs2.h | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/gfs2/libgfs2/libgfs2.h b/gfs2/libgfs2/libgfs2.h
index c04918b..4d219f4 100644
--- a/gfs2/libgfs2/libgfs2.h
+++ b/gfs2/libgfs2/libgfs2.h
@@ -612,12 +612,14 @@ do { print_log(1, MSG_CRITICAL, format); } while(0)
extern void increase_verbosity(void);
extern void decrease_verbosity(void);
extern void print_fsck_log(int iif, int priority, char *file, int line,
- const char *format, ...);
+ const char *format, ...)
+ __attribute__((format(printf,5,6)));
extern char generic_interrupt(const char *caller, const char *where,
const char *progress, const char *question,
const char *answers);
extern int gfs2_query(int *setonabort, struct gfs2_options *opts,
- const char *format, ...);
+ const char *format, ...)
+ __attribute__((format(printf,3,4)));
/* misc.c */
#define SYS_BASE "/sys/fs/gfs2"
@@ -686,7 +688,8 @@ extern int write_sb(struct gfs2_sbd *sdp);
/* ondisk.c */
extern uint32_t gfs2_disk_hash(const char *data, int len);
-extern void print_it(const char *label, const char *fmt, const char *fmt2, ...);
+extern void print_it(const char *label, const char *fmt, const char *fmt2, ...)
+ __attribute__((format(printf,3,4)));
__END_DECLS
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2009-02-19 10:09 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-19 10:09 cluster: STABLE3 - libgfs2: format checking for printf-like functions Fabio M. Di Nitto
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).