From owner-freebsd-bugs Mon Jul 27 08:01:10 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id IAA00416 for freebsd-bugs-outgoing; Mon, 27 Jul 1998 08:01:10 -0700 (PDT) (envelope-from owner-freebsd-bugs@FreeBSD.ORG) Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id IAA00406 for ; Mon, 27 Jul 1998 08:01:07 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.8.8/8.8.5) id IAA07889; Mon, 27 Jul 1998 08:00:01 -0700 (PDT) Received: from pc02.labcontrol.com (pc02.labcontrol.com [194.163.70.133]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id HAA00157 for ; Mon, 27 Jul 1998 07:59:08 -0700 (PDT) (envelope-from marc@pc02.labcontrol.com) Received: (from root@localhost) by pc02.labcontrol.com (8.8.8/8.8.7) id QAA26840; Mon, 27 Jul 1998 16:57:38 +0200 (CEST) (envelope-from marc) Message-Id: <199807271457.QAA26840@pc02.labcontrol.com> Date: Mon, 27 Jul 1998 16:57:38 +0200 (CEST) From: Marc van Woerkom Reply-To: lmarc@mail.labcontrol.com To: FreeBSD-gnats-submit@FreeBSD.ORG X-Send-Pr-Version: 3.2 Subject: bin/7414: userunfriendly error message from dmesg Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 7414 >Category: bin >Synopsis: userunfriendly error message from dmesg >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Mon Jul 27 08:00:01 PDT 1998 >Last-Modified: >Originator: & van Woerkom >Organization: >Release: FreeBSD 2.2.7-RELEASE i386 >Environment: >Description: when using dmesg to check what happened at boot time, I got "dmesg: incorrect magic number". I mistook this first, as having corrupted my dmesg by accident, but people from de-bsd-questions told me, that my kernel was older than my dmsg binary, simply. >How-To-Repeat: >Fix: I suggest this patch to clarify things (or put some hint on the man page) *** dmesg.c Mon Jul 27 15:29:07 1998 --- dmesg.c.original Thu Jun 25 02:45:59 1998 *************** *** 113,119 **** if (KREAD(nl[X_MSGBUF].n_value, bufp) || KREAD((long)bufp, cur)) errx(1, "kvm_read: %s", kvm_geterr(kd)); if (cur.msg_magic != MSG_MAGIC) ! errx(1, "magic number of kernel message buffer is incorrect"); bp = malloc(cur.msg_size); if (!bp) errx(1, "malloc failed"); --- 113,119 ---- if (KREAD(nl[X_MSGBUF].n_value, bufp) || KREAD((long)bufp, cur)) errx(1, "kvm_read: %s", kvm_geterr(kd)); if (cur.msg_magic != MSG_MAGIC) ! errx(1, "magic number incorrect"); bp = malloc(cur.msg_size); if (!bp) errx(1, "malloc failed"); Regards, Marc >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message