Skip to content
Commit cb06b385 authored by Alex Dewar's avatar Alex Dewar Committed by Greg Kroah-Hartman
Browse files

usb: atm: don't use snprintf() for sysfs attrs



kernel/cpu.c: don't use snprintf() for sysfs attrs

As per the documentation (Documentation/filesystems/sysfs.rst),
snprintf() should not be used for formatting values returned by sysfs.

In all of these cases, sprintf() suffices as we know that the formatted
strings will be less than PAGE_SIZE in length.

Issue identified by Coccinelle.

Signed-off-by: default avatarAlex Dewar <alex.dewar90@gmail.com>
Link: https://lore.kernel.org/r/20200824222322.22962-1-alex.dewar90@gmail.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 28157b8c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment