From 771d3e1d82cdf9286a002ef379a3edc7d62688f3 Mon Sep 17 00:00:00 2001 From: Julian Andres Klode Date: Fri, 26 Sep 2025 19:05:27 +0200 Subject: history-list: reject any arguments provided --- apt-private/private-history.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apt-private/private-history.cc b/apt-private/private-history.cc index 5057ed0d6..05c908471 100644 --- a/apt-private/private-history.cc +++ b/apt-private/private-history.cc @@ -205,6 +205,9 @@ bool DoHistoryList(CommandLine &Cmd) { HistoryBuffer buf = {}; + if (Cmd.FileSize() != 1) + return _error->Error("This command does not support any arguments"); + if (not ParseLogDir(buf)) return _error->Error(_("Could not read: %s"), _config->FindFile("Dir::Log::History").data()); -- cgit v1.2.3-70-g09d2