]> Git Repo - qemu.git/blobdiff - scripts/dump-guest-memory.py
Merge remote-tracking branch 'remotes/kraxel/tags/vga-20180618-pull-request' into...
[qemu.git] / scripts / dump-guest-memory.py
index 51acfcd0c0538c8d8b3e05d7199a1f53ccc6bc94..5a857cebcf64c9e2abcdaedb40e7ace092f22a25 100644 (file)
@@ -12,11 +12,17 @@ Authors:
 This work is licensed under the terms of the GNU GPL, version 2 or later. See
 the COPYING file in the top-level directory.
 """
+from __future__ import print_function
 
 import ctypes
 import struct
 
-UINTPTR_T = gdb.lookup_type("uintptr_t")
+try:
+    UINTPTR_T = gdb.lookup_type("uintptr_t")
+except Exception as inst:
+    raise gdb.GdbError("Symbols must be loaded prior to sourcing dump-guest-memory.\n"
+                       "Symbols may be loaded by 'attach'ing a QEMU process id or by "
+                       "'load'ing a QEMU binary.")
 
 TARGET_PAGE_SIZE = 0x1000
 TARGET_PAGE_MASK = 0xFFFFFFFFFFFFF000
This page took 0.023602 seconds and 4 git commands to generate.