Skip to content
Verified Commit c74d1ee6 authored by Stephen Kitt's avatar Stephen Kitt
Browse files

apt-cache: only show solutions if displayed



Currently, apt-cache [r]depends always shows all solutions for a
package, if appropriate, even if the package itself wasn’t displayed
(e.g. “--installed” was specified).

Thus, currently, with haskell-platform uninstalled and amd64 and i386
enabled, “apt-cache rdepends alex” shows

    alex
    Reverse Depends:
      haskell-platform
        alex:i386
      haskell-platform
        alex:i386

and “apt-cache rdepends alex --installed” shows

    alex
    Reverse Depends:
        alex:i386
        alex:i386

which is rather confusing.

This patch changes the behaviour so that solutions are only displayed
for packages which were themselves displayed;
“apt-cache rdepends alex --installed” then shows

    alex
    Reverse Depends:

Signed-off-by: default avatarStephen Kitt <skitt@debian.org>
parent 9ada8cb0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment