From a38cec81d349525c447004ef8fe9dc942c8bd9bb Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Wed, 16 Mar 2016 22:32:48 +0100 Subject: do not strip epochs from state version strings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The epoch stripping in this code is done since day one, but in other places we show a version epochs are not stripped. If epochs are present in packages they tend to be an important information which we can't just drop and especially can't drop "sometimes" as that confuses users and tools alike – so even if removing code in use for (close to) 18 years feels wrong, it is probably the right choice for consistency. Closes: 818162 --- apt-pkg/depcache.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'apt-pkg/depcache.h') diff --git a/apt-pkg/depcache.h b/apt-pkg/depcache.h index 10f869f25..99d0e7a63 100644 --- a/apt-pkg/depcache.h +++ b/apt-pkg/depcache.h @@ -209,7 +209,7 @@ class pkgDepCache : protected pkgCache::Namespace struct StateCache { - // Epoch stripped text versions of the two version fields + // text versions of the two version fields const char *CandVersion; const char *CurVersion; @@ -240,7 +240,7 @@ class pkgDepCache : protected pkgCache::Namespace unsigned char DepState; // DepState Flags // Update of candidate version - const char *StripEpoch(const char *Ver) APT_PURE; + APT_DEPRECATED_MSG("Use the method of the same name in contrib/strutl.h instead if you must") const char *StripEpoch(const char *Ver) APT_PURE; void Update(PkgIterator Pkg,pkgCache &Cache); // Various test members for the current status of the package -- cgit v1.2.3