projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9f9fdd8
)
atm: drv: Replace strcpy() + strlcat() with snprintf()
author
David Laight
<david.laight.linux@gmail.com>
Mon, 8 Jun 2026 09:55:20 +0000
(10:55 +0100)
committer
Jakub Kicinski
<kuba@kernel.org>
Wed, 10 Jun 2026 01:11:46 +0000
(18:11 -0700)
Avoid string function that are due to be deprecated.
Signed-off-by: David Laight <david.laight.linux@gmail.com>
Link:
https://patch.msgid.link/20260608095523.2606-36-david.laight.linux@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/usb/atm/ueagle-atm.c
patch
|
blob
|
history
diff --git
a/drivers/usb/atm/ueagle-atm.c
b/drivers/usb/atm/ueagle-atm.c
index
f3ae72f
..
11e3490
100644
(file)
--- a/
drivers/usb/atm/ueagle-atm.c
+++ b/
drivers/usb/atm/ueagle-atm.c
@@
-1572,10
+1572,8
@@
static void cmvs_file_name(struct uea_softc *sc, char *const cmv_name, int ver)
} else
file = cmv_file[sc->modem_index];
- strcpy(cmv_name, FW_DIR);
- strlcat(cmv_name, file, UEA_FW_NAME_MAX);
- if (ver == 2)
- strlcat(cmv_name, ".v2", UEA_FW_NAME_MAX);
+ snprintf(cmv_name, UEA_FW_NAME_MAX, FW_DIR "%s%s",
+ file, ver == 2 ? ".v2" : "");
kernel_param_unlock(THIS_MODULE);
}