From 2ca8cf36b78a3b19e170a4a3c76cb210148f1307 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Sun, 21 Jun 2015 19:34:43 +0900 Subject: [PATCH] util: Use constexpr for ALPN id --- src/util.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/util.h b/src/util.h index 88e1ff59..9ee2b115 100644 --- a/src/util.h +++ b/src/util.h @@ -52,11 +52,11 @@ namespace nghttp2 { // The additional HTTP/2 protocol ALPN protocol identifier we also // supports for our applications to make smooth migration into final // h2 ALPN ID. -#define NGHTTP2_H2_16_ALPN "\x5h2-16" -#define NGHTTP2_H2_16 "h2-16" +constexpr const char NGHTTP2_H2_16_ALPN[] = "\x5h2-16"; +constexpr const char NGHTTP2_H2_16[] = "h2-16"; -#define NGHTTP2_H2_14_ALPN "\x5h2-14" -#define NGHTTP2_H2_14 "h2-14" +constexpr const char NGHTTP2_H2_14_ALPN[] = "\x5h2-14"; +constexpr const char NGHTTP2_H2_14[] = "h2-14"; namespace util {