]> git.puffer.fish Git - matthieu/frr.git/commitdiff
vty: add some more defines for backwards compatibility
authorLou Berger <lberger@labn.net>
Tue, 11 Jul 2017 18:41:44 +0000 (14:41 -0400)
committerLou Berger <lberger@labn.net>
Tue, 11 Jul 2017 18:41:44 +0000 (14:41 -0400)
Signed-off-by: Lou Berger <lberger@labn.net>
lib/vty.h

index 61d6504edb2320f20d3bdbd66854b69fbbc6c5c3..b4a55180d39ca79eb8a3f531880eff09bfa84de1 100644 (file)
--- a/lib/vty.h
+++ b/lib/vty.h
@@ -186,6 +186,10 @@ struct vty_arg
 #define VTY_NEWLINE                               VTYNL
 #define VTY_GET_INTEGER(desc,v,str)               {(v)=strtoul ((str), NULL, 10);}
 #define VTY_GET_INTEGER_RANGE(desc,v,str,min,max) {(v)=strtoul ((str), NULL, 10);}
+#define VTY_GET_ULONG(desc,v,str)                 {(v)=strtoul ((str), NULL, 10);}
+#define VTY_GET_ULL(desc,v,str)                   {(v)=strtoull ((str), NULL, 10);}
+#define VTY_GET_IPV4_ADDRESS(desc,v,str)          inet_aton ((str), &(v))
+#define VTY_GET_IPV4_PREFIX(desc,v,str)           str2prefix_ipv4 ((str), &(v))
 
 /* Default time out value */
 #define VTY_TIMEOUT_DEFAULT 600