From owner-svn-src-all@FreeBSD.ORG Mon Nov 2 20:18:52 2009 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7B507106566B; Mon, 2 Nov 2009 20:18:52 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6AAB98FC1B; Mon, 2 Nov 2009 20:18:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id nA2KIpWP068435; Mon, 2 Nov 2009 20:18:51 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id nA2KIp6Q068433; Mon, 2 Nov 2009 20:18:51 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <200911022018.nA2KIp6Q068433@svn.freebsd.org> From: John Baldwin Date: Mon, 2 Nov 2009 20:18:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r198820 - head/sbin/ddb X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 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, 02 Nov 2009 20:18:52 -0000 Author: jhb Date: Mon Nov 2 20:18:50 2009 New Revision: 198820 URL: http://svn.freebsd.org/changeset/base/198820 Log: Ensure 'kvm' is always initialized. If "-M" was not specified and the garbage value on the stack was not zero, then 'ddb capture' would try to use the garbage value as a kvm_t pointer. MFC after: 1 week Modified: head/sbin/ddb/ddb_capture.c Modified: head/sbin/ddb/ddb_capture.c ============================================================================== --- head/sbin/ddb/ddb_capture.c Mon Nov 2 19:13:12 2009 (r198819) +++ head/sbin/ddb/ddb_capture.c Mon Nov 2 20:18:50 2009 (r198820) @@ -204,6 +204,7 @@ ddb_capture(int argc, char *argv[]) mflag = NULL; nflag = NULL; + kvm = NULL; while ((ch = getopt(argc, argv, "M:N:")) != -1) { switch (ch) { case 'M':