Browse Source

dpkg: Give more information on --set-selections warnings

Mention that the package cannot be found on the status nor available
database, and that to the FAQ.

Closes: #842230
Guillem Jover 7 years ago
parent
commit
4c379a6e21
2 changed files with 4 additions and 2 deletions
  1. 1 0
      debian/changelog
  2. 3 2
      src/select.c

+ 1 - 0
debian/changelog

@@ -54,6 +54,7 @@ dpkg (1.18.11) UNRELEASED; urgency=medium
     nor log the remove action.
   * Remove default «.» from @INC before loading perl modules in perl code.
     Fixes CVE-2016-1238.
+  * Give more information on --set-selections warnings. Closes: #842230
   * Architecture support:
     - Add support for AIX operating system.
   * Portability:

+ 3 - 2
src/select.c

@@ -182,7 +182,7 @@ setselections(const char *const *argv)
     if (!pkg_is_informative(pkg, &pkg->installed) &&
         !pkg_is_informative(pkg, &pkg->available)) {
       db_possibly_outdated = true;
-      warning(_("package not in database at line %d: %.250s"), lno, namevb.buf);
+      warning(_("package not in status nor available database at line %d: %.250s"), lno, namevb.buf);
       continue;
     }
 
@@ -201,7 +201,8 @@ setselections(const char *const *argv)
 
   if (db_possibly_outdated)
     warning(_("found unknown packages; this might mean the available database\n"
-              "is outdated, and needs to be updated through a frontend method"));
+              "is outdated, and needs to be updated through a frontend method;\n"
+              "please see the FAQ <https://wiki.debian.org/Teams/Dpkg/FAQ>"));
 
   return 0;
 }