Index: tools/grokdump.py |
diff --git a/tools/grokdump.py b/tools/grokdump.py |
index 59a2a48716d536af5101f479aeb0032f0b6a7179..24c9c5a92c10202031e974122535a2858077444b 100755 |
--- a/tools/grokdump.py |
+++ b/tools/grokdump.py |
@@ -1522,6 +1522,24 @@ class InspectionShell(cmd.Cmd): |
else: |
print "Page header is not available!" |
+ def do_da(self, address): |
+ """ |
+ Print ASCII string starting at specified address. |
+ """ |
+ address = int(address, 16) |
+ string = "" |
+ while self.reader.IsValidAddress(address): |
+ code = self.reader.ReadU8(address) |
+ if code < 128: |
+ string += chr(code) |
+ else: |
+ break |
+ address += 1 |
+ if string == "": |
+ print "Not an ASCII string at %s" % self.reader.FormatIntPtr(address) |
+ else: |
+ print "%s\n" % string |
+ |
def do_k(self, arguments): |
""" |
Teach V8 heap layout information to the inspector. This increases |