[Ocfs2-tools-devel] [PATCH 2/7] fsck.ocfs2: fix build warning

Joseph Qi joseph.qi at huawei.com
Fri Mar 4 01:45:57 PST 2016


Fix the following build warning:
warning: format ‘%u’ expects type ‘unsigned int’, but argument 7 has
type ‘long int’

Signed-off-by: Joseph Qi <joseph.qi at huawei.com>
---
 fsck.ocfs2/xattr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fsck.ocfs2/xattr.c b/fsck.ocfs2/xattr.c
index dbc86ab..b0b03ed 100644
--- a/fsck.ocfs2/xattr.c
+++ b/fsck.ocfs2/xattr.c
@@ -252,7 +252,7 @@ static errcode_t check_xattr_entry(o2fsck_state *ost,
 				    PRIu64" refers to a used area at %u,"
 				    " clear this entry?",
 				    xattr_object[xi->location], xi->blkno,
-				    XE_OFFSET(xh, xe))) {
+				    (uint32_t)XE_OFFSET(xh, xe))) {
 				ret = -1;
 				break;
 			} else
-- 
1.8.4.3





More information about the Ocfs2-tools-devel mailing list