summaryrefslogtreecommitdiffstats
path: root/ospf6d/ospf6_snmp.c
diff options
context:
space:
mode:
authorRemi Gacogne <rgacogne-github@coredump.fr>2013-09-08 15:48:34 +0200
committerVincent JARDIN <vincent.jardin@6wind.com>2014-02-11 10:28:03 +0100
commita11e012e8661629d665e992e765741a5eaa7d017 (patch)
treed6967d9c5044f8c924aa2f4b62bac8e3bda358e2 /ospf6d/ospf6_snmp.c
parentzebra: log routes w/o gateway in rib_delete_ipv4 (diff)
downloadfrr-a11e012e8661629d665e992e765741a5eaa7d017.tar.xz
frr-a11e012e8661629d665e992e765741a5eaa7d017.zip
security: Fix some typos and potential NULL-deref
This patch against the git tree fixes minor typos, some of them possibily leading to NULL-pointer dereference in rare conditions. Signed-off-by: Remi Gacogne <rgacogne-github@coredump.fr> Signed-off-by: Joachim Nilsson <troglobit@gmail.com> Acked-by: Feng Lu <lu.feng@6wind.com>
Diffstat (limited to 'ospf6d/ospf6_snmp.c')
-rw-r--r--ospf6d/ospf6_snmp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ospf6d/ospf6_snmp.c b/ospf6d/ospf6_snmp.c
index f8a3b9204..466039277 100644
--- a/ospf6d/ospf6_snmp.c
+++ b/ospf6d/ospf6_snmp.c
@@ -528,7 +528,7 @@ ospfv3AreaEntry (struct variable *v, oid *name, size_t *length,
return NULL;
len = *length - v->namelen;
- len = (len >= 1 ? sizeof 1 : 0);
+ len = (len >= 1 ? 1 : 0);
if (exact && len != 1)
return NULL;
if (len)