14 #define VTY_PRINTF_ATTRIBUTE(a,b) __attribute__ ((__format__ (__printf__, a, b)))
16 #define VTY_PRINTF_ATTRIBUTE(a,b)
20 #define ERRNO_IO_RETRY(EN) \
21 (((EN) == EAGAIN) || ((EN) == EWOULDBLOCK) || ((EN) == EINTR))
24 #define VTY_READ_BUFSIZ 512
26 #define VTY_BUFSIZ 512
27 #define VTY_MAXHIST 20
105 enum { VTY_NORMAL, VTY_CLOSE, VTY_MORE, VTY_MORELINE }
status;
119 #define TELNET_NAWS_SB_LEN 5
121 unsigned char sb_buf[TELNET_NAWS_SB_LEN];
142 #define VTY_NEWLINE ((vty->type == VTY_TERM) ? "\r\n" : "\n")
144 static inline const char *vty_newline(
struct vty *
vty)
168 void vty_init_vtysh (
void);
172 int vty_out (
struct vty *,
const char *, ...) VTY_PRINTF_ATTRIBUTE(2, 3);
177 char *vty_get_cwd (
void);
178 void vty_log (const
char *level, const
char *proto, const
char *fmt, va_list);
182 int vty_shell_serv (struct vty *);
183 void vty_hello (struct vty *);
186 enum
node_type vty_go_parent(struct vty *vty);
188 extern
void *tall_vty_ctx;