Skip to content

Instantly share code, notes, and snippets.

@shihyu
Forked from KevinKu/gdb_python_command_example
Created September 29, 2016 18:22
Show Gist options
  • Save shihyu/7d13091a724d6ce47b6279a06ac68c21 to your computer and use it in GitHub Desktop.
Save shihyu/7d13091a724d6ce47b6279a06ac68c21 to your computer and use it in GitHub Desktop.
import gdb
import string
class test_gdb_python_command(gdb.Command):
"test help"
def __init__(self):
super(test_gdb_python_command,self).__init__("test_gdb_python_command",gdb.COMMAND_USER)
def invoke(self,arg,from_tty):
print("gdb test")
test_gdb_python_command()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment