From owner-cvs-all@FreeBSD.ORG Thu Jul 22 23:16:12 2004 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9DD6F16A4CE; Thu, 22 Jul 2004 23:16:12 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7EFA243D1F; Thu, 22 Jul 2004 23:16:12 +0000 (GMT) (envelope-from imp@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.11/8.12.11) with ESMTP id i6MNGCjF018866; Thu, 22 Jul 2004 23:16:12 GMT (envelope-from imp@repoman.freebsd.org) Received: (from imp@localhost) by repoman.freebsd.org (8.12.11/8.12.11/Submit) id i6MNGC1t018865; Thu, 22 Jul 2004 23:16:12 GMT (envelope-from imp) Message-Id: <200407222316.i6MNGC1t018865@repoman.freebsd.org> From: Warner Losh Date: Thu, 22 Jul 2004 23:16:12 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/dev/sio sio.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 22 Jul 2004 23:16:12 -0000 imp 2004-07-22 23:16:12 UTC FreeBSD src repository Modified files: sys/dev/sio sio.c Log: If you insert a pccard modem and then eject it, you get a panic. This happens because the sio device was never opened and com->tp is therefore NULL. ttygone can't swallow a NULL, so guard against that possibility. Other places in this function make similar checks, so I believe this is correct. Revision Changes Path 1.450 +2 -1 src/sys/dev/sio/sio.c