Bug 319954 (MONO77153) - mdb can not examine instance variables.
Summary: mdb can not examine instance variables.
Status: RESOLVED FIXED
Alias: MONO77153
Product: Mono: Debugger
Classification: Mono
Component: backend (show other bugs)
Version: unspecified
Hardware: Other Other
: P3 - Medium : Normal
Target Milestone: ---
Assignee: Martin Baulig
QA Contact: Mono Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-01-04 15:39 UTC by Hans Kratz
Modified: 2007-09-15 21:24 UTC (History)
0 users

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
Testcase for reproducing the problem. (193.36 KB, application/octet-stream)
2006-01-04 15:41 UTC, Thomas Wiest
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Wiest 2007-09-15 19:43:24 UTC


---- Reported by kratz@omnicore.com 2006-01-04 08:39:45 MST ----

Debugger version 0.11. (This version is currently not selectable in 
Bugzilla) running on Mono 1.1.11.

Please fill in this template when reporting a bug, unless you know what you
are doing.
Description of Problem:


Steps to reproduce the problem:
1. Extract the archive
2. Run "mdb Program.exe" 
3. Enter "run"

Actual Results:
(mdb) run
Starting program: Program.exe
EXCEPTION: System.NullReferenceException: Object reference not set to an
instance of an object
in [0x00021] (at
/home/hans/mono-debugger-0.11/classes/SymbolTableManager.cs:109)
Mono.Debugger.SymbolTableManager:Lookup (TargetAddress address)
in (wrapper remoting-invoke-with-check)
Mono.Debugger.SymbolTableManager:Lookup (Mono.Debugger.TargetAddress)
in [0x00027] (at
/home/hans/mono-debugger-0.11/backends/SingleSteppingEngine.cs:593)
Mono.Debugger.Backends.SingleSteppingEngine:Lookup (TargetAddress address)
in [0x0002f] (at
/home/hans/mono-debugger-0.11/backends/SingleSteppingEngine.cs:875)
Mono.Debugger.Backends.SingleSteppingEngine:frame_changed (TargetAddress
address, Mono.Debugger.Backends.Operation operation)
in [0x00324] (at
/home/hans/mono-debugger-0.11/backends/SingleSteppingEngine.cs:314)
Mono.Debugger.Backends.SingleSteppingEngine:ProcessChildEvent
(Mono.Debugger.Backends.ChildEvent cevent)
in [0x000fe] (at
/home/hans/mono-debugger-0.11/backends/SingleSteppingEngine.cs:178)
Mono.Debugger.Backends.SingleSteppingEngine:ProcessEvent (Int32 status)
in (wrapper remoting-invoke-with-check)
Mono.Debugger.Backends.SingleSteppingEngine:ProcessEvent (int)
in [0x000c4] (at
/home/hans/mono-debugger-0.11/backends/ThreadManager.cs:454)
Mono.Debugger.Backends.ThreadManager:engine_thread_main ()


Expected Results:

No exception.

How often does this happen? 

Always reproducable.

Additional Information:



---- Additional Comments From kratz@omnicore.com 2006-01-04 08:41:35 MST ----

Created an attachment (id=169040)
Testcase for reproducing the problem.




---- Additional Comments From kratz@omnicore.com 2006-01-04 08:42:44 MST ----

The testcase is a .zip archive.



---- Additional Comments From martin@ximian.com 2006-04-18 13:05:55 MST ----

Old.



---- Additional Comments From miguel@ximian.com 2006-04-18 13:55:09 MST ----

I am reopening this bug, because while I tried to confirm this bug, I
found a new problem with the attached sources, which I built like this:

mcs -debug Program.cs -r:log4net.dll

Notice that when it crashes it is not possible to examine the value of
the 'buckets' instance variable, the debugger reports: 

ERROR: Cannot evaluate expression `buckets'


mdb Program.exe
(mdb) run
Starting program: Program.exe
Could not find file "/home/miguel/downloads/test/log4net.dll.mdb".
Could not find file "/mono/lib/mono/1.0/System.dll.mdb".
Thread @1 received signal 11 at #0: 0x411592a5 in
System.Xml.NameTable.AddEntry(System.String,System.Int32)+0x7d at
/home/cvs/mcs/class/System.XML/System.Xml/NameTable.cs:161.
 161                    buckets [bucket] = new Entry (str, hash,
buckets [bucket]);
(mdb) where
(*) #0: 0x411592a5 in
System.Xml.NameTable.AddEntry(System.String,System.Int32)+0x7d at
/home/cvs/mcs/class/System.XML/System.Xml/NameTable.cs:161
(mdb) p buckets
ERROR: Cannot evaluate expression `buckets'
(mdb) p hash
(System.Int32) 641750366
(mdb) p str
(System.String) "system.net"
(mdb) p buckets
ERROR: Cannot evaluate expression `buckets'
(mdb) list
 160                    int bucket = hash % count;
 161                    buckets [bucket] = new Entry (str, hash,
buckets [bucket]);
 162
 163                    // Grow whenever we double in size
 164                    if (size++ == count) {
 165                            count <<= 1;
 166                            int csub1 = count - 1;
 167
 168                            Entry [] newBuckets = new Entry [count];
 169                            for (int i = 0; i < buckets.Length; i++) {
(mdb) p this.buckets
ERROR: Cannot evaluate expression `buckets'
(mdb) list
 160                    int bucket = hash % count;
 161                    buckets [bucket] = new Entry (str, hash,
buckets [bucket]);
 162
 163                    // Grow whenever we double in size
 164                    if (size++ == count) {
 165                            count <<= 1;
 166                            int csub1 = count - 1;
 167
 168                            Entry [] newBuckets = new Entry [count];
 169                            for (int i = 0; i < buckets.Length; i++) {
(mdb) list -
 154
 155                    return null;
 156            }
 157
 158            string AddEntry (string str, int hash)
 159            {
 160                    int bucket = hash % count;
 161                    buckets [bucket] = new Entry (str, hash,
buckets [bucket]);
 162
 163                    // Grow whenever we double in size
(mdb) ptype this
class System.Xml.NameTable : System.Xml.XmlNameTable
{
   System.Int32 count;
   System.Xml.NameTable/Entry[] buckets;
   System.Int32 size;
   static System.Int32 INITIAL_BUCKETS;
   System.String Add (System.Char[], System.Int32, System.Int32);
   System.String Add (System.String);
   System.String Get (System.Char[], System.Int32, System.Int32);
   System.String Get (System.String);
   System.String AddEntry (System.String, System.Int32);
   static System.Boolean StrEqArray (System.String, System.Char[],
System.Int32);
   .ctor ();
}
(mdb) p this.buckets
ERROR: Cannot evaluate expression `buckets'




---- Additional Comments From martin@ximian.com 2006-05-12 09:00:27 MST ----

Closing old bug.

Imported an attachment (id=169040)

Unknown bug field "cf_op_sys_details" encountered while moving bug
   <cf_op_sys_details>Debian Sid - i686</cf_op_sys_details>
Unknown operating system unknown. Setting to default OS "Other".