diff options
author | paco <paco@voltanet.io> | 2018-06-20 19:25:06 +0200 |
---|---|---|
committer | paco <paco@voltanet.io> | 2018-06-20 19:25:06 +0200 |
commit | 7f61ea7bd47bfd86a2c873870507281b1837dcdd (patch) | |
tree | 46dec362108478c1e65efe877cc084d047df6dee /zebra/zebra_netns_notify.c | |
parent | Merge pull request #2498 from pacovn/Coverity_1470098_Logically_dead_code (diff) | |
download | frr-7f61ea7bd47bfd86a2c873870507281b1837dcdd.tar.xz frr-7f61ea7bd47bfd86a2c873870507281b1837dcdd.zip |
zebra: untrusted array index (Coverity 1470113)
This is a correction over 32ac96b2ba9693696d2f1156af1b80985d4e55bb, so
removing the forced string null termination doesn't involve a worse situation
than before (the underflow check should protect for the case of receiving
an incomplete buffer, which would be the cause of non-zero terminated string)
Signed-off-by: F. Aragon <paco@voltanet.io>
Diffstat (limited to 'zebra/zebra_netns_notify.c')
-rw-r--r-- | zebra/zebra_netns_notify.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/zebra/zebra_netns_notify.c b/zebra/zebra_netns_notify.c index bb6a56521..5feb87b59 100644 --- a/zebra/zebra_netns_notify.c +++ b/zebra/zebra_netns_notify.c @@ -216,7 +216,6 @@ static int zebra_ns_notify_read(struct thread *t) zlog_err("NS notify read: buffer underflow"); break; } - event->name[event->len] = 0; netnspath = ns_netns_pathname(NULL, event->name); if (!netnspath) continue; |