summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/ppp/ppp/bundle.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/usr.sbin/ppp/ppp/bundle.c b/usr.sbin/ppp/ppp/bundle.c
index b7a19a598f3..29aefb0739b 100644
--- a/usr.sbin/ppp/ppp/bundle.c
+++ b/usr.sbin/ppp/ppp/bundle.c
@@ -23,7 +23,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: bundle.c,v 1.19 1999/06/02 00:46:55 brian Exp $
+ * $Id: bundle.c,v 1.20 1999/06/22 11:32:44 brian Exp $
*/
#include <sys/param.h>
@@ -722,7 +722,7 @@ bundle_Create(const char *prefix, int type, const char **argv)
static struct bundle bundle; /* there can be only one */
int enoentcount, err;
const char *ifname;
-#ifdef TUNSIFMODE
+#if defined(TUNSIFMODE) || defined(TUNSLMODE)
int iff;
#endif
@@ -780,6 +780,14 @@ bundle_Create(const char *prefix, int type, const char **argv)
strerror(errno));
#endif
+#ifdef TUNSLMODE
+ /* Make sure we're POINTOPOINT */
+ iff = 0;
+ if (ID0ioctl(bundle.dev.fd, TUNSLMODE, &iff) < 0)
+ log_Printf(LogERROR, "bundle_Create: ioctl(TUNSLMODE): %s\n",
+ strerror(errno));
+#endif
+
if (!iface_SetFlags(bundle.iface, IFF_UP)) {
iface_Destroy(bundle.iface);
bundle.iface = NULL;