Skip to content

Commit 5b03698

Browse files
authored
Changed traffic_layout to report the version of PCRE2 (#12354)
1 parent a62efe1 commit 5b03698

1 file changed

Lines changed: 3 additions & 8 deletions

File tree

src/traffic_layout/info.cc

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,8 @@
3232
#include "info.h"
3333
#include "iocore/eventsystem/RecProcess.h"
3434

35-
#if __has_include("pcre/pcre.h")
36-
#include <pcre/pcre.h>
37-
#elif __has_include("pcre.h")
38-
#include <pcre.h>
39-
#else
40-
#error "Unable to locate PCRE heeader"
41-
#endif
35+
#define PCRE2_CODE_UNIT_WIDTH 8
36+
#include <pcre2.h>
4237

4338
#if TS_USE_HWLOC
4439
#include <hwloc.h>
@@ -189,7 +184,7 @@ produce_versions(bool json)
189184
print_var("libz", LBW().print("{}", ZLIB_VERSION).view(), json);
190185
print_var("openssl", LBW().print("{:#x}", OPENSSL_VERSION_NUMBER).view(), json);
191186
print_var("openssl_str", LBW().print(OPENSSL_VERSION_TEXT).view(), json);
192-
print_var("pcre", LBW().print("{}.{}", PCRE_MAJOR, PCRE_MINOR).view(), json);
187+
print_var("pcre2", LBW().print("{}.{}", PCRE2_MAJOR, PCRE2_MINOR).view(), json);
193188
// These are optional, for now at least.
194189
#if TS_USE_HWLOC
195190
print_var("hwloc", LBW().print("{:#x}", HWLOC_API_VERSION).view(), json);

0 commit comments

Comments
 (0)