diff options
author | Donald Sharp <sharpd@cumulusnetworks.com> | 2015-11-19 00:36:04 +0100 |
---|---|---|
committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2015-11-19 00:36:04 +0100 |
commit | db7c85284f7a1c472da0e905a0020ed02d37f539 (patch) | |
tree | e64915779a5cc411fbcd2894bc328899391b6ce5 /lib/json.h | |
parent | BGP: extcommunity-list are displayed before community-list (diff) | |
download | frr-db7c85284f7a1c472da0e905a0020ed02d37f539.tar.xz frr-db7c85284f7a1c472da0e905a0020ed02d37f539.zip |
Quagga: Fixup cli and json keyword
The json keyword was being read incorrectly.
Basically some commands read a variable # of arguments
and in ospf the command values were being placed into
argc and argv. With a variable # of arguments their
existed a possibility that less arguments would be read
from the cli than were being tested for in the command function
handler. This caused core dumps in some situations.
All code to read to decide to use the json keyword has
been centralized through a function and all code
converted to use it, irrelevant if it exhibited the bug
Ticket: CM-8278
Reviewed by: CCR-3830
Testing: OSPF no longer crashes and all other test suites still run
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'lib/json.h')
-rw-r--r-- | lib/json.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/json.h b/lib/json.h index e9b1976b9..e69b10acd 100644 --- a/lib/json.h +++ b/lib/json.h @@ -24,6 +24,7 @@ #include <json/json.h> +extern int use_json(const int argc, const char *argv[]); extern void json_object_string_add(struct json_object* obj, const char *key, const char *s); extern void json_object_int_add(struct json_object* obj, const char *key, |