8000 add explicit format specifier to printf() invocations · v4l2loopback/v4l2loopback@e4cd225 · GitHub
[go: up one dir, main page]

Skip to content

Commit e4cd225

Browse files
committed
add explicit format specifier to printf() invocations
CWE-134
1 parent 432e9a4 commit e4cd225

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

v4l2loopback.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -756,7 +756,7 @@ static int vidioc_querycap(struct file *file, void *priv,
756756
__u32 capabilities = V4L2_CAP_STREAMING | V4L2_CAP_READWRITE;
757757

758758
strlcpy(cap->driver, "v4l2 loopback", sizeof(cap->driver));
759-
snprintf(cap->card, labellen, dev->card_label);
759+
snprintf(cap->card, labellen, "%s", dev->card_label);
760760
snprintf(cap->bus_info, sizeof(cap->bus_info),
761761
"platform:v4l2loopback-%03d", device_nr);
762762

@@ -2494,7 +2494,7 @@ static int v4l2_loopback_add(struct v4l2_loopback_config *conf, int *ret_nr)
24942494
}
24952495

24962496
MARK();
2497-
snprintf(dev->vdev->name, sizeof(dev->vdev->name), dev->card_label);
2497+
snprintf(dev->vdev->name, sizeof(dev->vdev->name), "%s", dev->card_label);
24982498

24992499
vdev_priv->device_nr = nr;
25002500

0 commit comments

Comments
 (0)
0