]> git.ozlabs.org Git - ppp.git/blobdiff - pppd/auth.c
Multilink cleanups and fixes.
[ppp.git] / pppd / auth.c
index 4dfcb4382bdb2801e141ae6116bb84beeb3d956f..023653d5d15c0036e12437bdd6524779a2496253 100644 (file)
@@ -32,7 +32,7 @@
  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  */
 
-#define RCSID  "$Id: auth.c,v 1.61 2000/03/13 23:25:46 paulus Exp $"
+#define RCSID  "$Id: auth.c,v 1.64 2000/04/13 12:05:57 paulus Exp $"
 
 #include <stdio.h>
 #include <stddef.h>
@@ -509,6 +509,17 @@ start_networks()
     struct protent *protp;
 
     new_phase(PHASE_NETWORK);
+
+#ifdef HAVE_MULTILINK
+    if (multilink) {
+       if (mp_join_bundle()) {
+           if (updetach && !nodetach)
+               detach();
+           return;
+       }
+    }
+#endif /* HAVE_MULTILINK */
+
 #if 0
     if (!demand)
        set_filters(&pass_filter, &active_filter);
@@ -570,7 +581,7 @@ auth_peer_success(unit, protocol, name, namelen)
        namelen = sizeof(peer_authname) - 1;
     BCOPY(name, peer_authname, namelen);
     peer_authname[namelen] = 0;
-    script_setenv("PEERNAME", peer_authname);
+    script_setenv("PEERNAME", peer_authname, 0);
 
     /*
      * If there is no more authentication still to be done,