freebsd-nq/usr.sbin/ppp/log.h
Brian Somers 927145be97 Overhaul ppp:
o Use syslog
  o Remove references to stdout/stderr (incl perror())
  o Introduce VarTerm - the interactive terminal or zero
  o Allow "set timeout" to affect current session
  o Change "set debug" to "set log"
  o Allow "set log [+|-]flag"
  o Make MSEXT and PASSWDAUTH stuff the default
  o Move all #ifdef DEBUG stuff into the code - this
    shouldn't be too much overhead.  It's now controlled
    with "set log +debug"
  o Add "set log command, debug, tun, warn, error, alert"
  o Remove cdefs.h, and assume an ansi compiler.
  o Improve all diagnostic output
  o Don't trap SIGSEGV
  o SIGHUP now terminates again (log files are controlled
    by syslog)
  o Call CloseModem() when changing devices
  o Fix parsing of third arg of "delete"

I think this fixes the "magic is same" problems that some
people have been experiencing.
The man page is being rewritten.  It'll follow soon.
1997-06-09 03:27:43 +00:00

33 lines
1.1 KiB
C

#define LogMIN (1)
#define LogASYNC (1) /* syslog(LOG_INFO, ....) */
#define LogCARRIER (2)
#define LogCHAT (3)
#define LogCOMMAND (4)
#define LogCONNECT (5)
#define LogDEBUG (6) /* syslog(LOG_DEBUG, ....) */
#define LogHDLC (7)
#define LogLCP (8)
#define LogLINK (9)
#define LogLQM (10)
#define LogPHASE (11)
#define LogTCPIP (12)
#define LogTUN (13) /* If set, tun%d is output with each message */
#define LogMAXCONF (13)
#define LogWARN (14) /* Sent to VarTerm else syslog(LOG_WARNING, ) */
#define LogERROR (15) /* syslog(LOG_ERR, ....), + sent to VarTerm */
#define LogALERT (16) /* syslog(LOG_ALERT, ....) */
#define LogMAX (16)
/* The first int arg for all of the following is one of the above values */
extern const char *LogName(int);
extern void LogKeep(int);
extern void LogDiscard(int);
extern void LogDiscardAll();
extern int LogIsKept(int);
extern void LogOpen(const char *);
extern void LogSetTun(int);
extern void LogClose();
extern void LogPrintf(int, char *, ...);
extern void LogDumpBp(int, char *hdr, struct mbuf *bp);
extern void LogDumpBuff(int, char *hdr, u_char *ptr, int n);