Skip to content

Commit

Permalink
vendor: rhel5: fix build failure
Browse files Browse the repository at this point in the history
register_printf_specifier() doesn't exist in old OS like rhel5,
revert back to use register_printf_function().

Fixes: 5644bfc("tunefs.ocfs2: fix build warnings")
Signed-off-by: Junxiao Bi <[email protected]>
Reviewed-by: Joseph Qi <[email protected]>
  • Loading branch information
biger410 committed Nov 16, 2016
1 parent 8c7a3b5 commit 3e692a9
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions tunefs.ocfs2/op_query.c
Original file line number Diff line number Diff line change
Expand Up @@ -324,19 +324,19 @@ static int query_run(struct tunefs_operation *op, ocfs2_filesys *fs,
return 1;
}

register_printf_specifier('B', handle_blocksize, handle_arginfo);
register_printf_specifier('T', handle_clustersize, handle_arginfo);
register_printf_specifier('N', handle_numslots, handle_arginfo);
register_printf_specifier('R', handle_rootdir, handle_arginfo);
register_printf_specifier('Y', handle_sysdir, handle_arginfo);
register_printf_specifier('P', handle_clustergroup, handle_arginfo);

register_printf_specifier('V', handle_label, handle_arginfo);
register_printf_specifier('U', handle_uuid, handle_arginfo);

register_printf_specifier('M', handle_compat, handle_arginfo);
register_printf_specifier('H', handle_incompat, handle_arginfo);
register_printf_specifier('O', handle_ro_compat, handle_arginfo);
register_printf_function('B', handle_blocksize, handle_arginfo);
register_printf_function('T', handle_clustersize, handle_arginfo);
register_printf_function('N', handle_numslots, handle_arginfo);
register_printf_function('R', handle_rootdir, handle_arginfo);
register_printf_function('Y', handle_sysdir, handle_arginfo);
register_printf_function('P', handle_clustergroup, handle_arginfo);

register_printf_function('V', handle_label, handle_arginfo);
register_printf_function('U', handle_uuid, handle_arginfo);

register_printf_function('M', handle_compat, handle_arginfo);
register_printf_function('H', handle_incompat, handle_arginfo);
register_printf_function('O', handle_ro_compat, handle_arginfo);

query_fs = fs;
fprintf(stdout, fmt);
Expand Down

0 comments on commit 3e692a9

Please sign in to comment.