]> git.saurik.com Git - apt.git/blobdiff - apt-private/private-update.cc
support regular expressions in 'apt search'
[apt.git] / apt-private / private-update.cc
index a843d6f8684797b245f25416e3d7cf7f812d93f8..860d84b86ddfa7dc3af7225c86133c291323a7b0 100644 (file)
@@ -83,10 +83,10 @@ bool DoUpdate(CommandLine &CmdL)
       for (pkgCache::PkgIterator I = Cache->PkgBegin(); I.end() != true; ++I)
       {
          pkgDepCache::StateCache &state = Cache[I];
-         if (I->CurrentVer != 0 && state.Upgradable())
+         if (I->CurrentVer != 0 && state.Upgradable() && state.CandidateVer != NULL)
             upgradable++;
       }
-      const char *msg = ngettext(
+      const char *msg = P_(
          "%i package can be upgraded. Run 'apt list --upgradable' to see it.\n",
          "%i packages can be upgraded. Run 'apt list --upgradable' to see them.\n",
          upgradable);