From ab856f093a5345596804aa0b7e281dc71af3cb84 Mon Sep 17 00:00:00 2001 From: Emanuele Danovaro Date: Thu, 26 Oct 2023 11:07:07 +0100 Subject: [PATCH 1/4] version bump --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 2f4320f67..6521720b4 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.24.4 +1.24.5 From 92de2bdf83410c5406e88c1286e7c13a052d257b Mon Sep 17 00:00:00 2001 From: Emanuele Danovaro Date: Thu, 26 Oct 2023 11:07:44 +0100 Subject: [PATCH 2/4] URI added query removal --- src/eckit/filesystem/URI.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/eckit/filesystem/URI.cc b/src/eckit/filesystem/URI.cc index f30245e17..0dec1d4e0 100644 --- a/src/eckit/filesystem/URI.cc +++ b/src/eckit/filesystem/URI.cc @@ -219,7 +219,11 @@ std::string URI::authority() const { } void URI::query(const std::string& attribute, const std::string& value) { - queryValues_[attribute] = encode(value); + if (value.empty()) { + queryValues_.erase(attribute); + } else { + queryValues_[attribute] = encode(value); + } } const std::string URI::query(const std::string& attribute) const { From cd0f6e5fc4c819efebc7b4ddf069926b452668ac Mon Sep 17 00:00:00 2001 From: Emanuele Danovaro Date: Fri, 27 Oct 2023 12:31:58 +0100 Subject: [PATCH 3/4] endpoint hostport --- src/eckit/net/Endpoint.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/eckit/net/Endpoint.h b/src/eckit/net/Endpoint.h index 3fbb12e81..5ad08bcb2 100644 --- a/src/eckit/net/Endpoint.h +++ b/src/eckit/net/Endpoint.h @@ -38,6 +38,8 @@ class Endpoint { const std::string& host() const { return host_; } int port() const { return port_; } + std::string hostport() const { return host_+":"+std::to_string(port_); } + bool operator==(const net::Endpoint& other); void print(std::ostream& os) const; From 821d86902661e7f3cfe880505aef0a311b056c0d Mon Sep 17 00:00:00 2001 From: Emanuele Danovaro Date: Sun, 29 Oct 2023 08:39:06 +0000 Subject: [PATCH 4/4] PooledFile close --- src/eckit/io/PooledFile.cc | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/eckit/io/PooledFile.cc b/src/eckit/io/PooledFile.cc index 2de01763d..2eab33485 100644 --- a/src/eckit/io/PooledFile.cc +++ b/src/eckit/io/PooledFile.cc @@ -73,10 +73,9 @@ class PoolFileEntry { void remove(const PooledFile* file) { auto s = statuses_.find(file); - ASSERT(s != statuses_.end()); - - statuses_.erase(s); - + if (s != statuses_.end()) { + statuses_.erase(s); + } if (statuses_.size() == 0) { doClose(); pool_.erase(name_); @@ -114,10 +113,10 @@ class PoolFileEntry { void close(const PooledFile* file) { auto s = statuses_.find(file); - ASSERT(s != statuses_.end()); - - ASSERT(s->second.opened_); - s->second.opened_ = false; + if (s != statuses_.end()) { + ASSERT(s->second.opened_); + s->second.opened_ = false; + } } int fileno(const PooledFile* file) const {