RCS file: /home/jdp/f5/pptp/cvs/pptp/pty.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -r1.1.1.1 -r1.2 --- pty.h 1999/04/28 19:36:57 1.1.1.1 +++ pty.h 1999/04/28 19:42:34 1.2 @@ -6,18 +6,32 @@ * $Id: pty.h,v 1.2 1997/12/13 08:39:01 cananian Exp $ */ -/* Hmm. PTYs can be anywhere.... */ - #ifdef __linux__ -#define PTYDEV "/dev/ptyxx" -#define TTYDEV "/dev/ttyxx" +#define PTYCHAR1 "abcdepqrstuvwxyz" +#define PTYCHAR2 "0123456789abcdef" +#endif -#define PTYMAX (strlen(PTYDEV)+1) -#define TTYMAX (strlen(TTYDEV)+1) +#ifdef __FreeBSD__ +#define PTYCHAR1 "pqrsPQRS" +#define PTYCHAR2 "0123456789abcdefghijklmnopqrstuv" +#endif -#define PTYCHAR1 "abcdepqrstuvwxyz" +/* Conservative defaults that will work for most systems. */ +#ifndef PTYDEV +#define PTYDEV "/dev/ptyxx" +#endif +#ifndef TTYDEV +#define TTYDEV "/dev/ttyxx" +#endif +#ifndef PTYCHAR1 +#define PTYCHAR1 "pqrs" +#endif +#ifndef PTYCHAR2 #define PTYCHAR2 "0123456789abcdef" #endif + +#define PTYMAX (strlen(PTYDEV)+1) +#define TTYMAX (strlen(TTYDEV)+1) /* Get pty/tty pair, put filename in ttydev, ptydev (which must be * at least PTYMAX characters long), and return file descriptor of