diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2025-06-04 07:49:21 +0300 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2025-06-04 07:51:27 +0300 |
commit | ce098f2aded8d0f6f41bb9ab069c3f3c8ef5fc42 (patch) | |
tree | 804cf2aa7b9a916ddf1e93ad326cf54277f72b22 /drivers/input | |
parent | 1babc858cce111d744baf9a015ec65a19aafbbea (diff) | |
download | linux-ce098f2aded8d0f6f41bb9ab069c3f3c8ef5fc42.tar.xz |
Input: lifebook - switch to use scnprintf() to suppress truncation warning
Switch the driver to use scnprintf() to avoid warnings about potential
truncation of "phys" field which we can tolerate.
Reported-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input')
-rw-r--r-- | drivers/input/mouse/lifebook.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/input/mouse/lifebook.c b/drivers/input/mouse/lifebook.c index 7147dacc404f..283ef46f039f 100644 --- a/drivers/input/mouse/lifebook.c +++ b/drivers/input/mouse/lifebook.c @@ -279,8 +279,8 @@ static int lifebook_create_relative_device(struct psmouse *psmouse) goto err_out; priv->dev2 = dev2; - snprintf(priv->phys, sizeof(priv->phys), - "%s/input1", psmouse->ps2dev.serio->phys); + scnprintf(priv->phys, sizeof(priv->phys), + "%s/input1", psmouse->ps2dev.serio->phys); dev2->phys = priv->phys; dev2->name = "LBPS/2 Fujitsu Lifebook Touchpad"; |