Przeglądaj źródła

dpkg (1.2.2); priority=MEDIUM

  * Fixed dselect coredump found by Erick Branderhorst (thanks).
  * Sort obsolete removed packages separately, not under Available.

 -- Ian Jackson <ian@chiark.chu.cam.ac.uk>  Thu, 23 May 1996 21:31:05 +0100
Ian Jackson 30 lat temu
rodzic
commit
ac65bf8031
6 zmienionych plików z 27 dodań i 8 usunięć
  1. 7 0
      debian.Changelog
  2. 1 1
      debian.rules
  3. 2 1
      dselect/pkgdepcon.cc
  4. 4 2
      dselect/pkgdisplay.cc
  5. 12 4
      dselect/pkglist.cc
  6. 1 0
      dselect/pkglist.h

+ 7 - 0
debian.Changelog

@@ -1,3 +1,10 @@
+dpkg (1.2.2); priority=MEDIUM
+
+  * Fixed dselect coredump found by Erick Branderhorst (thanks).
+  * Sort obsolete removed packages separately, not under Available.
+
+ -- Ian Jackson <ian@chiark.chu.cam.ac.uk>  Thu, 23 May 1996 21:31:05 +0100
+
 dpkg (1.2.1); priority=MEDIUM
 dpkg (1.2.1); priority=MEDIUM
 
 
   * `=' key in dselect really does `hold' rather than `unhold'.
   * `=' key in dselect really does `hold' rather than `unhold'.

+ 1 - 1
debian.rules

@@ -1,7 +1,7 @@
 #!/usr/bin/make -f
 #!/usr/bin/make -f
 
 
 package=dpkg
 package=dpkg
-version=1.2.1
+version=1.2.2
 
 
 archi=$(shell dpkg --print-architecture)
 archi=$(shell dpkg --print-architecture)
 DIR:=$(shell pwd)
 DIR:=$(shell pwd)

+ 2 - 1
dselect/pkgdepcon.cc

@@ -35,8 +35,9 @@ extern "C" {
 static const int depdebug= 1;
 static const int depdebug= 1;
 
 
 int packagelist::useavailable(pkginfo *pkg) {
 int packagelist::useavailable(pkginfo *pkg) {
-  if (informative(pkg,&pkg->available) &&
+  if (pkg->clientdata &&
       pkg->clientdata->selected == pkginfo::want_install &&
       pkg->clientdata->selected == pkginfo::want_install &&
+      informative(pkg,&pkg->available) &&
       (pkg->status != pkginfo::stat_installed ||
       (pkg->status != pkginfo::stat_installed ||
        versioncompare(&pkg->available.version,&pkg->installed.version) > 1))
        versioncompare(&pkg->available.version,&pkg->installed.version) > 1))
     return 1;
     return 1;

+ 4 - 2
dselect/pkgdisplay.cc

@@ -59,13 +59,15 @@ const char
                          "Updated",
                          "Updated",
                          "Obsolete/local",
                          "Obsolete/local",
                          "Up-to-date",
                          "Up-to-date",
-                         "Available" },
+                         "Available",
+                         "Removed" },
   *const ssastrings[]= { "Brokenly installed packages",
   *const ssastrings[]= { "Brokenly installed packages",
                          "Newly available packages",
                          "Newly available packages",
                          "Updated packages (newer version is available)",
                          "Updated packages (newer version is available)",
                          "Obsolete and local packages present on system",
                          "Obsolete and local packages present on system",
                          "Up to date installed packages",
                          "Up to date installed packages",
-                         "Available packages (not currently installed)" };
+                         "Available packages (not currently installed)",
+                         "Removed and no longer available packages" };
 
 
 const char
 const char
   *const sssstrings[]= { "Brokenly installed packages",
   *const sssstrings[]= { "Brokenly installed packages",

+ 12 - 4
dselect/pkglist.cc

@@ -153,6 +153,7 @@ void packagelist::sortinplace() {
 void packagelist::ensurestatsortinfo() {
 void packagelist::ensurestatsortinfo() {
   const struct versionrevision *veri;
   const struct versionrevision *veri;
   const struct versionrevision *vera;
   const struct versionrevision *vera;
+  struct pkginfo *pkg;
   int index;
   int index;
   
   
   if (debug) fprintf(debug,"packagelist[%p]::ensurestatsortinfos() "
   if (debug) fprintf(debug,"packagelist[%p]::ensurestatsortinfos() "
@@ -170,7 +171,10 @@ void packagelist::ensurestatsortinfo() {
       if (debug)
       if (debug)
         fprintf(debug,"packagelist[%p]::ensurestatsortinfos() i=%d pkg=%s\n",
         fprintf(debug,"packagelist[%p]::ensurestatsortinfos() i=%d pkg=%s\n",
                 this,index,table[index]->pkg->name);
                 this,index,table[index]->pkg->name);
-      switch (table[index]->pkg->status) {
+      pkg= table[index]->pkg;
+      if (!pkg->installed.valid) blankpackageperfile(&pkg->installed);
+      if (!pkg->available.valid) blankpackageperfile(&pkg->available);
+      switch (pkg->status) {
       case pkginfo::stat_unpacked:
       case pkginfo::stat_unpacked:
       case pkginfo::stat_halfconfigured:
       case pkginfo::stat_halfconfigured:
       case pkginfo::stat_halfinstalled:
       case pkginfo::stat_halfinstalled:
@@ -178,9 +182,13 @@ void packagelist::ensurestatsortinfo() {
         break;
         break;
       case pkginfo::stat_notinstalled:
       case pkginfo::stat_notinstalled:
       case pkginfo::stat_configfiles:
       case pkginfo::stat_configfiles:
-        table[index]->ssavail=
-          table[index]->original == pkginfo::want_unknown
-            ? ssa_notinst_unseen : ssa_notinst_seen;
+        if (!informativeversion(&pkg->available.version)) {
+          table[index]->ssavail= ssa_notinst_gone;
+        } else if (table[index]->original == pkginfo::want_unknown) {
+          table[index]->ssavail= ssa_notinst_unseen;
+        } else {
+          table[index]->ssavail= ssa_notinst_seen;
+        }
         break;
         break;
       case pkginfo::stat_installed:
       case pkginfo::stat_installed:
         veri= &table[index]->pkg->installed.version;
         veri= &table[index]->pkg->installed.version;

+ 1 - 0
dselect/pkglist.h

@@ -46,6 +46,7 @@ enum ssavailval {        // Availability sorting order, first to last:
   ssa_installed_gone,    //   Installed but no longer available
   ssa_installed_gone,    //   Installed but no longer available
   ssa_installed_sameold, //   Same or older version available as installed
   ssa_installed_sameold, //   Same or older version available as installed
   ssa_notinst_seen,      //   Available but not installed
   ssa_notinst_seen,      //   Available but not installed
+  ssa_notinst_gone,      //   Not available, and only config files left
   ssa_none=-1
   ssa_none=-1
 };
 };