|
84 | 84 | from io import StringIO, TextIOWrapper
|
85 | 85 | from types import ModuleType
|
86 | 86 | from typing import (Any, ByteString, Callable, Dict, Generator, Iterable,
|
87 |
| - Iterator, List, NoReturn, Optional, OrderedDict, Sequence, Set, Tuple, Type, TypeVar, |
| 87 | + Iterator, List, NoReturn, Optional, Sequence, Set, Tuple, Type, TypeVar, |
88 | 88 | Union, cast)
|
89 | 89 | from urllib.request import urlopen
|
90 | 90 |
|
@@ -6466,7 +6466,6 @@ def do_invoke(self, _: List[str], **kwargs: Any) -> None:
|
6466 | 6466 | return
|
6467 | 6467 | try:
|
6468 | 6468 | arena_addr = parse_address(args.arena_address)
|
6469 |
| - print(f"{arena_addr=:#x}") |
6470 | 6469 | arena = GlibcArena(f"*{arena_addr:#x}")
|
6471 | 6470 | self.dump_chunks_arena(arena, ctx)
|
6472 | 6471 | except gdb.error:
|
@@ -9678,8 +9677,8 @@ def __init__(self) -> None:
|
9678 | 9677 | gef.config["gef.main_arena_offset"] = GefSetting("", str, "Offset from libc base address to main_arena symbol (int or hex). Set to empty string to disable.")
|
9679 | 9678 | gef.config["gef.propagate_debug_exception"] = GefSetting(False, bool, "If true, when debug mode is enabled, Python exceptions will be propagated all the way.")
|
9680 | 9679 |
|
9681 |
| - self.commands : OrderedDict[str, GenericCommand] = collections.OrderedDict() |
9682 |
| - self.functions : OrderedDict[str, GenericFunction] = collections.OrderedDict() |
| 9680 | + self.commands : Dict[str, GenericCommand] = collections.OrderedDict() |
| 9681 | + self.functions : Dict[str, GenericFunction] = collections.OrderedDict() |
9683 | 9682 | self.missing: Dict[str, Exception] = {}
|
9684 | 9683 | return
|
9685 | 9684 |
|
@@ -10121,13 +10120,13 @@ def __init__(self) -> None:
|
10121 | 10120 |
|
10122 | 10121 | def invoke(self, args: Any, from_tty: bool) -> None:
|
10123 | 10122 | self.dont_repeat()
|
10124 |
| - missing_commands = gef.gdb.missing |
| 10123 | + missing_commands: Dict[str, Exception] = gef.gdb.missing |
10125 | 10124 | if not missing_commands:
|
10126 | 10125 | ok("No missing command")
|
10127 | 10126 | return
|
10128 | 10127 |
|
10129 |
| - for missing_command, reason in missing_commands.items(): |
10130 |
| - warn(f"Command `{missing_command}` is missing, reason {RIGHT_ARROW} {reason}") |
| 10128 | + for cmd, reason in missing_commands.items(): |
| 10129 | + warn(f"Missing `{cmd}`, reason: {str(reason)}") |
10131 | 10130 | return
|
10132 | 10131 |
|
10133 | 10132 |
|
|
0 commit comments