mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-09 14:50:58 +00:00
lib: Fix condition for snprintf
Signed-off-by: Donald Lee <dlqs@gmx.com>
This commit is contained in:
parent
84c92002d2
commit
9e3a277b04
@ -276,7 +276,7 @@ int frrscript_load(struct frrscript *fs, const char *function_name,
|
|||||||
|
|
||||||
if (snprintf(script_name, sizeof(script_name), "%s/%s.lua", scriptdir,
|
if (snprintf(script_name, sizeof(script_name), "%s/%s.lua", scriptdir,
|
||||||
fs->name)
|
fs->name)
|
||||||
< 0) {
|
>= (int)sizeof(script_name)) {
|
||||||
zlog_err("frrscript: path to script %s/%s.lua is too long",
|
zlog_err("frrscript: path to script %s/%s.lua is too long",
|
||||||
scriptdir, fs->name);
|
scriptdir, fs->name);
|
||||||
goto fail;
|
goto fail;
|
||||||
|
Loading…
Reference in New Issue
Block a user