Skip to content

Commit

Permalink
xen-netback: fix possible format string flaw
Browse files Browse the repository at this point in the history
This makes sure a format string cannot accidentally leak into the
kthread_run() call.

Signed-off-by: Kees Cook <[email protected]>
Acked-by: Ian Campbell <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
kees authored and davem330 committed Sep 12, 2013
1 parent b0dd663 commit a9677bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/xen-netback/interface.c
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ int xenvif_connect(struct xenvif *vif, unsigned long tx_ring_ref,

init_waitqueue_head(&vif->wq);
vif->task = kthread_create(xenvif_kthread,
(void *)vif, vif->dev->name);
(void *)vif, "%s", vif->dev->name);
if (IS_ERR(vif->task)) {
pr_warn("Could not allocate kthread for %s\n", vif->dev->name);
err = PTR_ERR(vif->task);
Expand Down

0 comments on commit a9677bc

Please sign in to comment.