From fenner@parc.xerox.com  Thu May 29 14:38:50 1997
Received: from alpha.xerox.com (alpha.Xerox.COM [13.1.64.93])
          by hub.freebsd.org (8.8.5/8.8.5) with SMTP id OAA11093
          for <FreeBSD-gnats-submit@freebsd.org>; Thu, 29 May 1997 14:38:49 -0700 (PDT)
Received: from klute.parc.xerox.com ([13.2.116.207]) by alpha.xerox.com with SMTP id <17907(6)>; Thu, 29 May 1997 14:38:08 PDT
Received: from sundae.parc.xerox.com ([13.2.117.33]) by klute.parc.xerox.com with SMTP id <59220>; Thu, 29 May 1997 14:38:00 PDT
Received: (from fenner@localhost)
	by sundae.parc.xerox.com (8.8.5/8.8.5) id VAA00447;
	Thu, 29 May 1997 21:38:00 GMT
Message-Id: <199705292138.VAA00447@sundae.parc.xerox.com>
Date: Thu, 29 May 1997 14:38:00 PDT
From: Bill Fenner <fenner@parc.xerox.com>
Reply-To: fenner@parc.xerox.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: gdb -w -k /kernel /dev/mem != gdb --wcore --kernel /kernel /dev/mem
X-Send-Pr-Version: 3.2

>Number:         3714
>Category:       gnu
>Synopsis:       gdb -w -k /kernel /dev/mem != gdb --wcore --kernel /kernel /dev/mem
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu May 29 14:40:01 PDT 1997
>Closed-Date:    Wed Apr 29 06:25:26 PDT 1998
>Last-Modified:  Wed Apr 29 06:26:02 PDT 1998
>Originator:     Bill Fenner
>Release:        FreeBSD 2.2-RELEASE i386
>Organization:
Xerox
>Environment:

	
FreeBSD 2.2-RELEASE

>Description:

	
gdb -w -k /kernel /dev/mem does not allow writing to variables,
nor does gdb --w --k /kernel /dev/mem.
gdb --wcore --kernel /kernel /dev/mem does.


>How-To-Repeat:

	
# gdb -w -k /kernel /dev/mem
GDB is free software and you are welcome to distribute copies of it
 under certain conditions; type "show copying" to see the conditions.
There is absolutely no warranty for GDB; type "show warranty" for details.
GDB 4.16 (i386-unknown-freebsd), 
Copyright 1996 Free Software Foundation, Inc...(no debugging symbols found)...
IdlePTD 26e000
current pcb at 183e000
#0  0xf0118c63 in ?? ()
(kgdb) set tcpconsdebug = 0
kvm_write:write failed
(kgdb) quit

# gdb --w --k /kernel /dev/mem
GDB is free software and you are welcome to distribute copies of it
 under certain conditions; type "show copying" to see the conditions.
There is absolutely no warranty for GDB; type "show warranty" for details.
GDB 4.16 (i386-unknown-freebsd), 
Copyright 1996 Free Software Foundation, Inc...(no debugging symbols found)...
IdlePTD 26e000
current pcb at 769000
#0  0xf0118c63 in ?? ()
(kgdb) set tcpconsdebug = 0
kvm_write:write failed
(kgdb) quit

# gdb --wcore --kernel /kernel /dev/mem
GDB is free software and you are welcome to distribute copies of it
 under certain conditions; type "show copying" to see the conditions.
There is absolutely no warranty for GDB; type "show warranty" for details.
GDB 4.16 (i386-unknown-freebsd), 
Copyright 1996 Free Software Foundation, Inc...(no debugging symbols found)...
IdlePTD 26e000
current pcb at ad4000
#0  0xf0118c63 in ?? ()
(kgdb) set tcpconsdebug = 0
(kgdb) quit


>Fix:
	
	
Unknown.  Perhaps this is a gnu getopt_long_only bug.
>Release-Note:
>Audit-Trail:

From: Bill Fenner <fenner@parc.xerox.com>
To: freebsd-gnats-submit@freebsd.org
Cc:  Subject: Re: gnu/3714
Date: Thu, 29 May 1997 14:50:32 PDT

 D'oh, sometimes it takes submitting a bug report before you realize
 what you're doing wrong.  gdb already has a "-w" option, "use windows".
 Presumably this means that /usr/src/gnu/usr.bin/gdb/nm.h should lose its
 "w" argument definition, since it can't ever be used.
 
 P.S. Is there a reason to add libiberty twice in
 src/gnu/usr.bin/gdb/gdb/Makefile?  "make -d v" reveals:
 
 Global:LDADD = -L${.OBJDIR}/../bfd -lbfd -lreadline  -lgnuregex -L${.OBJDIR}/../libiberty -liberty -ltermcap -L${.OBJDIR}/../libiberty -liberty
 
State-Changed-From-To: open->closed 
State-Changed-By: phk 
State-Changed-When: Wed Apr 29 06:25:26 PDT 1998 
State-Changed-Why:  
I like the french (?)  expression :-) 
>Unformatted:
