Guest User

Untitled

a guest
Jun 24th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.00 KB | None | 0 0
  1. - if type.code == gdb.TYPE_CODE_STRUCT:
  2. - try:
  3. - # Check whether it's an array.
  4. - arraylen = value["length"]
  5. - arrayptr = value["ptr"]
  6. - self.putType(type)
  7. - self.putAddress(value.address)
  8. - if str(type) == "struct char[]":
  9. - self.putValue(encodeCharArray(arrayptr, arraylen),
  10. - Hex2EncodedLatin1)
  11. - self.putNumChild(0)
  12. - else:
  13. - self.putNumChild(arraylen)
  14. - self.putItemCount(arraylen)
  15. - if self.isExpanded(item):
  16. - with Children(self):
  17. - for i in range(arraylen):
  18. - v = arrayptr.dereference()
  19. - self.putSubItem(Item(v, item.iname))
  20. - arrayptr += 1
  21. - return
  22. - except:
  23. - pass
Add Comment
Please, Sign In to add comment