This is an automated email from the ASF dual-hosted git repository.

cmcfarlen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/master by this push:
     new e4fab322b4 Fix header_rewrite loading remap mmdb files (#12126)
e4fab322b4 is described below

commit e4fab322b45c0250e0a019b41cb590ef5ee521df
Author: Chris McFarlen <[email protected]>
AuthorDate: Fri Mar 28 18:14:44 2025 -0500

    Fix header_rewrite loading remap mmdb files (#12126)
---
 plugins/header_rewrite/CMakeLists.txt    | 2 +-
 plugins/header_rewrite/header_rewrite.cc | 3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/plugins/header_rewrite/CMakeLists.txt 
b/plugins/header_rewrite/CMakeLists.txt
index b342cdccbb..e1a8ef7bc6 100644
--- a/plugins/header_rewrite/CMakeLists.txt
+++ b/plugins/header_rewrite/CMakeLists.txt
@@ -38,7 +38,7 @@ target_link_libraries(header_rewrite_parser PUBLIC 
libswoc::libswoc)
 
 target_link_libraries(
   header_rewrite
-  PRIVATE PCRE::PCRE
+  PRIVATE OpenSSL::Crypto PCRE::PCRE
   PUBLIC libswoc::libswoc
 )
 
diff --git a/plugins/header_rewrite/header_rewrite.cc 
b/plugins/header_rewrite/header_rewrite.cc
index 96a3fe31a4..b4f2da2505 100644
--- a/plugins/header_rewrite/header_rewrite.cc
+++ b/plugins/header_rewrite/header_rewrite.cc
@@ -507,10 +507,9 @@ TSRemapNewInstance(int argc, char *argv[], void **ih, char 
* /* errbuf ATS_UNUSE
     }
 
     Dbg(pi_dbg_ctl, "Remap geo db %s", geoDBpath.c_str());
+    std::call_once(initHRWLibs, [&geoDBpath]() { initHRWLibraries(geoDBpath); 
});
   }
 
-  std::call_once(initHRWLibs, [&geoDBpath]() { initHRWLibraries(geoDBpath); });
-
   RulesConfig *conf = new RulesConfig;
 
   for (int i = optind; i < argc; ++i) {

Reply via email to