mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-09 00:43:08 -04:00
netfilter: nftables: Add __printf() attribute
nft_request_module calls vsnprintf() using parameters passed to it. Make the function with __printf() attribute so the compiler can check the format and arguments. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
committed by
Pablo Neira Ayuso
parent
3976ca1019
commit
35b7ee34ab
@@ -581,7 +581,8 @@ struct nft_module_request {
|
||||
};
|
||||
|
||||
#ifdef CONFIG_MODULES
|
||||
static int nft_request_module(struct net *net, const char *fmt, ...)
|
||||
static __printf(2, 3) int nft_request_module(struct net *net, const char *fmt,
|
||||
...)
|
||||
{
|
||||
char module_name[MODULE_NAME_LEN];
|
||||
struct nft_module_request *req;
|
||||
|
||||
Reference in New Issue
Block a user