From e566bddaff55548b9c8ecddd9adece90451c4e58 Mon Sep 17 00:00:00 2001 From: Vadim Yanitskiy Date: Tue, 6 Oct 2020 17:41:22 +0700 Subject: vty: introduce and use VTY_CMD_USR_ATTR_NUM Change-Id: Ib4327835f5be264ef67a01d8f4733dd2d091eaf1 Related: SYS#4937 --- include/osmocom/vty/vty.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/include/osmocom/vty/vty.h b/include/osmocom/vty/vty.h index fcef08e0..9cadb7ac 100644 --- a/include/osmocom/vty/vty.h +++ b/include/osmocom/vty/vty.h @@ -28,6 +28,9 @@ #define VTY_BUFSIZ 512 #define VTY_MAXHIST 20 +/* Number of application / library specific VTY attributes */ +#define VTY_CMD_USR_ATTR_NUM 32 + /*! VTY events */ enum event { VTY_SERV, @@ -193,9 +196,9 @@ struct vty_app_info { /*! Check if the config is consistent before write */ int (*config_is_consistent)(struct vty *vty); /*! Description of the application specific VTY attributes (optional). */ - const char * usr_attr_desc[32]; + const char * usr_attr_desc[VTY_CMD_USR_ATTR_NUM]; /*! Flag letters of the application specific VTY attributes (optional). */ - char usr_attr_letters[32]; + char usr_attr_letters[VTY_CMD_USR_ATTR_NUM]; }; /* Prototypes. */ -- cgit v1.2.3