diff options
Diffstat (limited to 'lib/vty.c')
| -rw-r--r-- | lib/vty.c | 14 |
1 files changed, 9 insertions, 5 deletions
@@ -24,11 +24,16 @@ #include <lib/version.h> #include <sys/types.h> #include <sys/types.h> -#ifdef HAVE_LIBPCREPOSIX +#ifdef HAVE_LIBPCRE2_POSIX +#ifndef _FRR_PCRE2_POSIX +#define _FRR_PCRE2_POSIX +#include <pcre2posix.h> +#endif /* _FRR_PCRE2_POSIX */ +#elif defined(HAVE_LIBPCREPOSIX) #include <pcreposix.h> #else #include <regex.h> -#endif /* HAVE_LIBPCREPOSIX */ +#endif /* HAVE_LIBPCRE2_POSIX */ #include <stdio.h> #include "linklist.h" @@ -53,9 +58,7 @@ #include <arpa/telnet.h> #include <termios.h> -#ifndef VTYSH_EXTRACT_PL #include "lib/vty_clippy.c" -#endif DEFINE_MTYPE_STATIC(LIB, VTY, "VTY"); DEFINE_MTYPE_STATIC(LIB, VTY_SERV, "VTY server"); @@ -444,7 +447,8 @@ static int vty_command(struct vty *vty, char *buf) /* * Log non empty command lines */ - if (do_log_commands) + if (do_log_commands && + strncmp(buf, "echo PING", strlen("echo PING")) != 0) cp = buf; if (cp != NULL) { /* Skip white spaces. */ |
