Annotation of libaitcli/inc/defs.h, revision 1.2.2.3
1.1 misho 1: /*************************************************************************
2: * (C) 2010 AITNET ltd - Sofia/Bulgaria - <misho@aitbg.com>
3: * by Michael Pounov <misho@openbsd-bg.org>
4: *
5: * $Author: misho $
1.2.2.3 ! misho 6: * $Id: defs.h,v 1.2.2.2 2010/06/04 12:46:27 misho Exp $
1.1 misho 7: *
8: *************************************************************************/
9: #ifndef __DEFS_H
10: #define __DEFS_H
11:
12:
1.2.2.1 misho 13: #define MAX_BINDKEY 559
1.1 misho 14:
1.2.2.1 misho 15: #define HISTORY_LINES 100
16: #define HISTORY_FILE "/tmp/.aitcli.history"
17:
18: #define CLI_PROMPT "aitCLI> "
19:
20: #define LINEMODE_RAW -1
21: #define LINEMODE_INS 0
22: #define LINEMODE_OVER 1
23:
24: #define RETCODE_ERR -1
25: #define RETCODE_OK 0
26: #define RETCODE_EOL 1
27: #define RETCODE_EOF 2
1.1 misho 28:
1.2 misho 29: #define DEFAULT_SOCK_TIMEOUT 60
30:
1.2.2.3 ! misho 31: #define MAX_PROMPT_ITEMS 21
! 32:
1.1 misho 33: #define LOGERR { \
34: cli_Errno = errno; \
35: strlcpy(cli_Error, strerror(errno), STRSIZ); \
36: }
37:
38:
39: extern int cli_Errno;
40: extern char cli_Error[];
41:
42: inline void cli_SetErr(int eno, char *estr, ...);
43:
44:
45: #endif
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>