Contact cannot be a null ptr, and it is accessed before anyway. Disscussed with kedge.
[kdenetwork.git] / kppp / kpppconfig.h
bloba09fd81521bdfe9e8ce67ed6d094376e8d556b49
1 /* -*- C++ -*-
2 * kPPP: A pppd front end for the KDE project
4 * $Id$
6 * Copyright (C) 1997 Bernd Johannes Wuebben
7 * wuebben@math.cornell.edu
10 * This program is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU Library General Public
12 * License as published by the Free Software Foundation; either
13 * version 2 of the License, or (at your option) any later version.
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 * Library General Public License for more details.
20 * You should have received a copy of the GNU Library General Public
21 * License along with this program; if not, write to the Free
22 * Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
26 #ifndef _KPPPCONFIG_H_
27 #define _KPPPCONFIG_H_
29 #if defined(__svr4__)
30 #define STREAMS
31 #define _XOPEN_SOURCE 1
32 #define _XOPEN_SOURCE_EXTENDED 1
33 #define __EXTENSIONS__
34 #endif
36 #include <config-kppp.h>
38 #ifdef HAVE_SYS_PARAM_H
39 #include <sys/param.h>
40 #endif
42 // Warning: If you fiddle with the following directories you have
43 // to adjust make_directories() in main.cpp()
45 // file used for PAP authetication purposes
46 #define PAP_AUTH_FILE "/etc/ppp/pap-secrets"
48 // file used for CHAP authetication purposes
49 #define CHAP_AUTH_FILE "/etc/ppp/chap-secrets"
51 // Define the default modem response timeout
52 #define MODEM_TIMEOUT 60
54 // Define the default modem tone duration (ATS11=)
55 #define MODEM_TONEDURATION 70
57 // Define the default time for pppd to get the interface up
58 #define PPPD_TIMEOUT 30
60 // Define the default time to wait after a busy signal before redialing
61 #define BUSY_WAIT 0
65 // Every PPP_STATS_INTERVAL milli seconds kppp will read
66 // and display the ppp statistics IF the stats window
67 // is visible. If the stats window is not visible
68 // the stats are not taken.
69 // 200 milli secs is 5 times per second and results in
70 // 0 load on my machine. Play with this parameter if
71 // you feel like it.
73 #define PPP_STATS_INTERVAL 200
74 // comment this out to get some more debugging info
76 #define MY_DEBUG
79 // Define the maximum number of accounts
80 #define MAX_ACCOUNTS 100
82 // Define the maximum number of modems
83 #define MAX_MODEMS 100
85 // Define the mamimum number of script entries
86 #define MAX_SCRIPT_ENTRIES 20
88 // Define the maximun number of DNS entries
89 #define MAX_DNS_ENTRIES 5
91 // Maximum size of the command executing pppd
92 const int MAX_CMDLEN = 2024;
94 // Define the maximum number of arguments passed to the pppd daemon
95 #define MAX_PPPD_ARGUMENTS 20
97 // Define the maximun number of lines of /etc/resolv.conf
98 #define MAX_RESOLVCONF_LINES 128
100 // Directory for modem lock files (Needed by mgetty users)
101 #ifdef __linux__
102 # define LOCK_DIR "/var/lock"
103 #else /* linux */
104 # ifdef BSD
105 # define LOCK_DIR "/var/spool/lock"
106 # else /* BSD */
107 # define LOCK_DIR "/var/spool/locks"
108 # endif /* BSD */
109 #endif /* linux */
111 // search path for pppd binary
112 #define PPPDSEARCHPATH "/sbin:/usr/sbin:/usr/local/sbin:/usr/bin:/usr/local/bin"
114 // name of the pppd binary
115 #define PPPDNAME "pppd"
117 // support for internal ISDN cards and modem emulation
118 #ifdef __linux__
119 #define ISDNSUPPORT
120 #endif
122 #if defined(__linux__) || defined(BSD)
123 #define PPP_PID_DIR "/var/run/"
124 #else
125 #define PPP_PID_DIR "/etc/ppp/"
126 #endif
128 // defined in opener.cpp
129 extern const char * const kppp_syslog[];
131 #ifdef _XPG4_2
132 #define __xnet_connect connect
133 #endif
135 #define CBTYPE_NONE 0
136 #define CBTYPE_ADMIN 1
137 #define CBTYPE_USER 2
139 #endif