FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Cluster Development

 
 
LinkBack Thread Tools
 
Old 11-10-2010, 08:19 PM
Joe Perches
 
Default fs/gfs2/glock.h: Add __attribute__((format(printf, 2, 3)) to gfs2_print_dbg

Functions that use printf formatting, especially
those that use %pV, should have their uses of
printf format and arguments checked by the compiler.

Signed-off-by: Joe Perches <joe@perches.com>
---
No current uses report any error in an allyesconfig build.

fs/gfs2/glock.h | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/fs/gfs2/glock.h b/fs/gfs2/glock.h
index db1c26d..a12d117 100644
--- a/fs/gfs2/glock.h
+++ b/fs/gfs2/glock.h
@@ -212,6 +212,8 @@ int gfs2_glock_nq_num(struct gfs2_sbd *sdp,
int gfs2_glock_nq_m(unsigned int num_gh, struct gfs2_holder *ghs);
void gfs2_glock_dq_m(unsigned int num_gh, struct gfs2_holder *ghs);
void gfs2_glock_dq_uninit_m(unsigned int num_gh, struct gfs2_holder *ghs);
+
+__attribute__ ((format(printf, 2, 3)))
void gfs2_print_dbg(struct seq_file *seq, const char *fmt, ...);

/**
 
Old 11-10-2010, 08:35 PM
Steven Whitehouse
 
Default fs/gfs2/glock.h: Add __attribute__((format(printf, 2, 3)) to gfs2_print_dbg

Hi,

Now in the GFS2 -nmw git tree. Thanks,

Steve.

On Wed, 2010-11-10 at 13:19 -0800, Joe Perches wrote:
> Functions that use printf formatting, especially
> those that use %pV, should have their uses of
> printf format and arguments checked by the compiler.
>
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
> No current uses report any error in an allyesconfig build.
>
> fs/gfs2/glock.h | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/fs/gfs2/glock.h b/fs/gfs2/glock.h
> index db1c26d..a12d117 100644
> --- a/fs/gfs2/glock.h
> +++ b/fs/gfs2/glock.h
> @@ -212,6 +212,8 @@ int gfs2_glock_nq_num(struct gfs2_sbd *sdp,
> int gfs2_glock_nq_m(unsigned int num_gh, struct gfs2_holder *ghs);
> void gfs2_glock_dq_m(unsigned int num_gh, struct gfs2_holder *ghs);
> void gfs2_glock_dq_uninit_m(unsigned int num_gh, struct gfs2_holder *ghs);
> +
> +__attribute__ ((format(printf, 2, 3)))
> void gfs2_print_dbg(struct seq_file *seq, const char *fmt, ...);
>
> /**
>
>
 

Thread Tools




All times are GMT. The time now is 07:04 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org