client/test/maxadmin_test.sh: added new cases for testing maxadmin
service.c:dListListeners:fixed NULL-pointer reference
debugcli.h: replaced magic number 80 with constant integer.
cli.c:execute:fixed command buffer overflow
debugcmd.c:convert_arg:restored return value to 0 in case of error
This commit is contained in:
VilhoRaatikka
2015-01-19 17:55:02 +02:00
parent 9c34125a59
commit 5d1f029260
5 changed files with 217 additions and 43 deletions

View File

@ -52,12 +52,14 @@ typedef struct cli_instance {
* The CLI_SESSION structure. As CLI_SESSION is created for each user that logs into
* the DEBUG CLI.
*/
enum { cmdbuflen=80 };
typedef struct cli_session {
char cmdbuf[80]; /*< The command buffer used to build up user commands */
int mode; /*< The CLI Mode for this session */
SESSION *session; /*< The gateway session */
char cmdbuf[cmdbuflen]; /*< The command buffer used to build up user commands */
int mode; /*< The CLI Mode for this session */
SESSION *session; /*< The gateway session */
struct cli_session
*next; /*< The next pointer for the list of sessions */
*next; /*< The next pointer for the list of sessions */
} CLI_SESSION;
/* Command line interface modes */