Added ELF sections check so a potential unknown section will stop, or not stop, the...
[clinton/Virtual-Jaguar-Rx.git] / src / debugger / DWARFManager.cpp
index 4ff8abb..fed680a 100644 (file)
@@ -28,7 +28,7 @@
 \r
 \r
 // Definitions for debugging\r
-//#define DEBUG_NumCU                  0x9                                     // CU number to debug or undefine it\r
+//#define DEBUG_NumCU                  0x4d                            // CU number to debug or undefine it\r
 //#define DEBUG_VariableName   "sound_death"                           // Variable name to look for or undefine it\r
 //#define DEBUG_TypeName               "Cbuf_Execute"                  // Type name to look for or undefine it\r
 //#define DEBUG_TypeDef                        DW_TAG_typedef          // Type def to look for or undefine it (not supported)\r
@@ -1188,7 +1188,10 @@ void DWARFManager_InitInfosVariable(VariablesStruct *PtrVariables)
                                        PtrVariables->TypeTag |= TypeTag_structure;\r
                                        if (!(PtrVariables->TypeTag & TypeTag_typedef))\r
                                        {\r
-                                               strcat(PtrVariables->PtrTypeName, PtrCU[NbCU].PtrTypes[j].PtrName);\r
+                                               if (PtrCU[NbCU].PtrTypes[j].PtrName)\r
+                                               {\r
+                                                       strcat(PtrVariables->PtrTypeName, PtrCU[NbCU].PtrTypes[j].PtrName);\r
+                                               }\r
                                        }\r
                                        if ((TypeOffset = PtrCU[NbCU].PtrTypes[j].TypeOffset))\r
                                        {\r