diff --git a/pwndbg/commands/context.py b/pwndbg/commands/context.py index 2e614c86a..6294eaf0e 100644 --- a/pwndbg/commands/context.py +++ b/pwndbg/commands/context.py @@ -337,6 +337,8 @@ def serve_context_history(function: Callable[P, List[str]]) -> Callable[P, List[ def history_handle_unchanged_contents() -> None: + if not context_history: + return longest_history = max(len(h) for h in context_history.values()) for section_name, history in context_history.items(): # Duplicate the last entry if it is the same as the previous one