summaryrefslogtreecommitdiff
path: root/apt-pkg
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg')
-rw-r--r--apt-pkg/deb/debmetaindex.h2
-rw-r--r--apt-pkg/metaindex.cc7
-rw-r--r--apt-pkg/metaindex.h2
3 files changed, 2 insertions, 9 deletions
diff --git a/apt-pkg/deb/debmetaindex.h b/apt-pkg/deb/debmetaindex.h
index 5bdbbc70c..5576ff809 100644
--- a/apt-pkg/deb/debmetaindex.h
+++ b/apt-pkg/deb/debmetaindex.h
@@ -59,7 +59,7 @@ class APT_HIDDEN debReleaseIndex : public metaIndex
bool IsArchitectureAllSupportedFor(IndexTarget const &target) const override;
bool HasSupportForComponent(std::string const &component) const override;
- APT_PURE time_t GetNotBefore() const;
+ APT_PURE time_t GetNotBefore() const override;
void AddComponent(std::string const &sourcesEntry,
bool const isSrc, std::string const &Name,
diff --git a/apt-pkg/metaindex.cc b/apt-pkg/metaindex.cc
index 9a1e8a696..06db06f83 100644
--- a/apt-pkg/metaindex.cc
+++ b/apt-pkg/metaindex.cc
@@ -66,13 +66,6 @@ APT_PURE std::string metaIndex::GetReleaseNotes() const { return ReleaseNotes; }
APT_PURE signed short metaIndex::GetDefaultPin() const { return DefaultPin; }
APT_PURE bool metaIndex::GetSupportsAcquireByHash() const { return SupportsAcquireByHash; }
APT_PURE time_t metaIndex::GetValidUntil() const { return ValidUntil; }
-APT_PURE time_t metaIndex::GetNotBefore() const
-{
- debReleaseIndex const *const deb = dynamic_cast<debReleaseIndex const *>(this);
- if (deb != nullptr)
- return deb->GetNotBefore();
- return 0;
-}
APT_PURE time_t metaIndex::GetDate() const { return this->Date; }
APT_PURE metaIndex::TriState metaIndex::GetLoadedSuccessfully() const { return LoadedSuccessfully; }
APT_PURE std::string metaIndex::GetExpectedDist() const { return Dist; }
diff --git a/apt-pkg/metaindex.h b/apt-pkg/metaindex.h
index 015cb3621..1c1cada0c 100644
--- a/apt-pkg/metaindex.h
+++ b/apt-pkg/metaindex.h
@@ -73,7 +73,7 @@ public:
bool GetSupportsAcquireByHash() const;
time_t GetValidUntil() const;
time_t GetDate() const;
- APT_HIDDEN time_t GetNotBefore() const; // FIXME make virtual
+ virtual time_t GetNotBefore() const = 0;
std::string GetExpectedDist() const;
bool CheckDist(std::string const &MaybeDist) const;