]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - packages/Python/lldbsuite/test/python_api/default-constructor/sb_instructionlist.py
Vendor import of lldb trunk r256945:
[FreeBSD/FreeBSD.git] / packages / Python / lldbsuite / test / python_api / default-constructor / sb_instructionlist.py
1 """
2 Fuzz tests an object after the default construction to make sure it does not crash lldb.
3 """
4
5 import sys
6 import lldb
7
8 def fuzz_obj(obj):
9     obj.GetSize()
10     obj.GetInstructionAtIndex(0xffffffff)
11     obj.AppendInstruction(lldb.SBInstruction())
12     obj.Print(None)
13     obj.GetDescription(lldb.SBStream())
14     obj.DumpEmulationForAllInstructions("armv7")
15     obj.Clear()
16     for inst in obj:
17         s = str(inst)