Skip to content

Commit

Permalink
Revert ABI breakage in kiwix::Downloader::getDownloadIds()
Browse files Browse the repository at this point in the history
Changing it to be `const` is an ABI change since the symbol changes from
`_ZN5...` to `_ZNK5...` (addition of "K").

The other changes made in 18b7b5f are probably fine to keep since they
don't appear to be used from what I can tell.

Fixes #998.
  • Loading branch information
legoktm committed Sep 14, 2023
1 parent bde737f commit 9fd2f55
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion include/downloader.h
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ class Downloader
/**
* Get the ids of the managed downloads.
*/
std::vector<std::string> getDownloadIds() const;
std::vector<std::string> getDownloadIds();

private:
mutable std::mutex m_lock;
Expand Down
2 changes: 1 addition & 1 deletion src/downloader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ void Downloader::close()
mp_aria->close();
}

std::vector<std::string> Downloader::getDownloadIds() const {
std::vector<std::string> Downloader::getDownloadIds() {

Check warning on line 160 in src/downloader.cpp

View check run for this annotation

Codecov / codecov/patch

src/downloader.cpp#L160

Added line #L160 was not covered by tests
std::unique_lock<std::mutex> lock(m_lock);
std::vector<std::string> ret;
for(auto& p:m_knownDownloads) {
Expand Down

0 comments on commit 9fd2f55

Please sign in to comment.