From: Paul Mackerras Date: Tue, 13 Jan 2004 04:00:34 +0000 (+0000) Subject: Don't fall over if the channel doesn't have a disconnect method. X-Git-Tag: ppp-2.4.7~261 X-Git-Url: https://git.ozlabs.org/?a=commitdiff_plain;h=ea0c6c5be54c2fdada12e2c1e5292dee9b12b9ac;p=ppp.git Don't fall over if the channel doesn't have a disconnect method. --- diff --git a/pppd/main.c b/pppd/main.c index 8631566..1c570ee 100644 --- a/pppd/main.c +++ b/pppd/main.c @@ -40,7 +40,7 @@ * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#define RCSID "$Id: main.c,v 1.130 2003/12/17 08:56:05 kad Exp $" +#define RCSID "$Id: main.c,v 1.131 2004/01/13 04:00:34 paulus Exp $" #include #include @@ -589,7 +589,8 @@ main(argc, argv) */ disconnect: new_phase(PHASE_DISCONNECT); - the_channel->disconnect(); + if (the_channel->disconnect) + the_channel->disconnect(); fail: if (the_channel->cleanup)