Summary: | NPE at frysk.value.TypeDecorator.<init>(FryskGui) | ||
---|---|---|---|
Product: | frysk | Reporter: | Sami Wagiaalla <swagiaal> |
Component: | general | Assignee: | Unassigned <frysk-bugzilla> |
Status: | ASSIGNED --- | ||
Severity: | normal | ||
Priority: | P2 | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Host: | Target: | ||
Build: | Last reconfirmed: | ||
Bug Depends on: | |||
Bug Blocks: | 1633, 5675 |
Description
Sami Wagiaalla
2008-01-25 15:22:23 UTC
the type thhat is causing the crash can be found here: file: /usr/src/debug/bash-3.2/lib/readline/input.c line: 461 col: 0 provided by bash-debuginfo-3.2-19.fc8 here is a snapshot the type is FILE *stream: int rl_getc (stream) FILE *stream; { int result; unsigned char c; Handle "typedef void" (bug 5669). * TypeEntry.java (getType): DwTag.TYPEDEF_: Handle "typedef void" * gen-type-funit-tests.py (main): Add ptr_void_type_var. [0.0] 1 typedef void void_type; 2 void_type *void_type_pointer; 3 4 main() { -> 5 void *i = 0; 6 *(int*)i ++; 7 return 0; 8 } (fhpd) print void_type_pointer (void_type *) 0x0 (fhpd) print void_type_pointer --type void_type * (fhpd) ptype void_type Error: Unknown command: ptype (fhpd) type void_type Error: Unknown command: type (fhpd) what void_type Error: null (fhpd) +++ b/frysk-core/frysk/debuginfo/TypeEntry.java @@ -437,7 +437,11 @@ public class TypeEntry { switch (type.getTag().hashCode()) { case DwTag.TYPEDEF_: - returnType = new TypeDef(type.getName(), getType(type.getType())); + DwarfDie typedefDieType = type.getType(); + Type typedefType = (typedefDieType != null) + ? getType(typedefDieType) + : new UnknownType(type.getName()); + returnType = new TypeDef(type.getName(), typedefType); break; case DwTag.POINTER_TYPE_: { Type ptrTarget = getType(type.getType()); a note explaining how this can occur would be useful; and should this be UnknownType or previously created void type? What does the DWARF spec say? |