Skip to content

Commit 138aef7

Browse files
Daniel Borkmannummakynes
authored andcommitted
netfilter: nf_conntrack_dccp: use %s format string for buffer
Some invocations of nf_log_packet() use arg buffer directly instead of "%s" format string with follow-up buffer pointer. Currently, these two usages are not really critical, but we should fix this up nevertheless so that we don't run into trouble if that changes one day. Signed-off-by: Daniel Borkmann <dborkman@redhat.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
1 parent 2a50d80 commit 138aef7

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎net/netfilter/nf_conntrack_proto_dccp.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -457,7 +457,7 @@ static bool dccp_new(struct nf_conn *ct, const struct sk_buff *skb,
457457
out_invalid:
458458
if (LOG_INVALID(net, IPPROTO_DCCP))
459459
nf_log_packet(net, nf_ct_l3num(ct), 0, skb, NULL, NULL,
460-
NULL, msg);
460+
NULL, "%s", msg);
461461
return false;
462462
}
463463

@@ -614,7 +614,7 @@ static int dccp_error(struct net *net, struct nf_conn *tmpl,
614614

615615
out_invalid:
616616
if (LOG_INVALID(net, IPPROTO_DCCP))
617-
nf_log_packet(net, pf, 0, skb, NULL, NULL, NULL, msg);
617+
nf_log_packet(net, pf, 0, skb, NULL, NULL, NULL, "%s", msg);
618618
return -NF_ACCEPT;
619619
}
620620

0 commit comments

Comments
 (0)