Skip to content

Commit d612a07

Browse files
arndbtytso
authored andcommitted
ext4: avoid -Wformat-security warning
check_igot_inode() prints a variable string, which causes a harmless warning with 'make W=1': fs/ext4/inode.c:4763:45: error: format string is not a string literal (potentially insecure) [-Werror,-Wformat-security] 4763 | ext4_error_inode(inode, function, line, 0, err_str); Use a trivial "%s" format string instead. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Reviewed-by: Jan Kara <jack@suse.cz> Link: https://patch.msgid.link/20250423164354.2780635-1-arnd@kernel.org Signed-off-by: Theodore Ts'o <tytso@mit.edu>
1 parent 24b7a23 commit d612a07

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/ext4/inode.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4809,7 +4809,7 @@ static int check_igot_inode(struct inode *inode, ext4_iget_flags flags,
48094809
return 0;
48104810

48114811
error:
4812-
ext4_error_inode(inode, function, line, 0, err_str);
4812+
ext4_error_inode(inode, function, line, 0, "%s", err_str);
48134813
return -EFSCORRUPTED;
48144814
}
48154815

0 commit comments

Comments
 (0)