From owner-svn-src-all@freebsd.org Mon Aug 8 19:31:02 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E1B4FBB3FE7; Mon, 8 Aug 2016 19:31:02 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B4C411D3C; Mon, 8 Aug 2016 19:31:02 +0000 (UTC) (envelope-from sbruno@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u78JV1IJ026578; Mon, 8 Aug 2016 19:31:01 GMT (envelope-from sbruno@FreeBSD.org) Received: (from sbruno@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u78JV1Ve026577; Mon, 8 Aug 2016 19:31:01 GMT (envelope-from sbruno@FreeBSD.org) Message-Id: <201608081931.u78JV1Ve026577@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sbruno set sender to sbruno@FreeBSD.org using -f From: Sean Bruno Date: Mon, 8 Aug 2016 19:31:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r303848 - head/sys/netgraph X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Aug 2016 19:31:03 -0000 Author: sbruno Date: Mon Aug 8 19:31:01 2016 New Revision: 303848 URL: https://svnweb.freebsd.org/changeset/base/303848 Log: Avoid panic from ng_uncallout when unpluggin ethernet cable with active PPTP VPN connection. Submitted by: Michael Zhilin Reviewed by: ngie MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D7209 Modified: head/sys/netgraph/ng_base.c Modified: head/sys/netgraph/ng_base.c ============================================================================== --- head/sys/netgraph/ng_base.c Mon Aug 8 18:57:50 2016 (r303847) +++ head/sys/netgraph/ng_base.c Mon Aug 8 19:31:01 2016 (r303848) @@ -3815,7 +3815,7 @@ ng_uncallout(struct callout *c, node_p n item = c->c_arg; /* Do an extra check */ if ((rval > 0) && (c->c_func == &ng_callout_trampoline) && - (NGI_NODE(item) == node)) { + (item != NULL) && (NGI_NODE(item) == node)) { /* * We successfully removed it from the queue before it ran * So now we need to unreference everything that was