Fix authentication on second time around with multilink and persist
authorPaul Mackerras <paulus@samba.org>
Wed, 26 Nov 2008 10:02:29 +0000 (21:02 +1100)
committerPaul Mackerras <paulus@samba.org>
Wed, 26 Nov 2008 10:02:29 +0000 (21:02 +1100)
Frédéric Brière reported that when using multilink and persist, pppd
would fail to authenticate itself on the second and subsequent times
of bringing up a bundle.  The reason was that the doing_multilink and
multilink_master flags never got reset when the first bundle was
destroyed.  This adds lines to mp_bundle_terminated to do that.

Signed-off-by: Paul Mackerras <paulus@samba.org>
pppd/multilink.c

index b4748cd6c885d30b023b5efd6d0f338f46429a0a..135cab0b42ad419d1c4297240cf464ca6b83b14f 100644 (file)
@@ -278,8 +278,11 @@ void mp_bundle_terminated()
        key.dsize = strlen(blinks_id);
        tdb_delete(pppdb, key);
        unlock_db();
-       
-new_phase(PHASE_DEAD);
+
+       new_phase(PHASE_DEAD);
+
+       doing_multilink = 0;
+       multilink_master = 0;
 }
 
 static void make_bundle_links(int append)