summaryrefslogtreecommitdiff
path: root/lib/json.h
diff options
context:
space:
mode:
authorRuss White <russ@riw.us>2017-11-29 07:44:39 -0500
committerGitHub <noreply@github.com>2017-11-29 07:44:39 -0500
commit1d04ad057dfff692b38ac97b317b226ec52c482e (patch)
tree9e6e9fcf385b5953f53e7a74979d84709eea924d /lib/json.h
parent074f2a3789d0d0ee31493b9e22d5aad0b1e93a7e (diff)
parent0f478e3050ce918402bcc718569c8918cc1eef4a (diff)
Merge pull request #1482 from chiragshah6/mdev1
ospfd: Running-config display ospf (non active) vrf config, OSPF Route json support
Diffstat (limited to 'lib/json.h')
-rw-r--r--lib/json.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/json.h b/lib/json.h
index e3e55ab962..675d852af7 100644
--- a/lib/json.h
+++ b/lib/json.h
@@ -52,4 +52,19 @@ extern void json_object_free(struct json_object *obj);
#define JSON_STR "JavaScript Object Notation\n"
+/* NOTE: json-c lib has following commit 316da85 which
+ * handles escape of forward slash.
+ * This allows prefix "20.0.14.0\/24":{
+ * to "20.0.14.0/24":{ some platforms do not have
+ * latest copy of json-c where defining below macro.
+ */
+
+#ifndef JSON_C_TO_STRING_NOSLASHESCAPE
+
+/**
+ * Don't escape forward slashes.
+ */
+#define JSON_C_TO_STRING_NOSLASHESCAPE (1<<4)
+#endif
+
#endif /* _QUAGGA_JSON_H */