Compare commits
3 Commits
Author | SHA1 | Date |
---|---|---|
Tatsuhiro Tsujikawa | 6384375098 | |
Tatsuhiro Tsujikawa | 27801e98ae | |
Tatsuhiro Tsujikawa | 60e020a85b |
|
@ -24,7 +24,7 @@
|
|||
|
||||
cmake_minimum_required(VERSION 3.0)
|
||||
# XXX using 1.8.90 instead of 1.9.0-DEV
|
||||
project(nghttp2 VERSION 1.35.0)
|
||||
project(nghttp2 VERSION 1.35.1)
|
||||
|
||||
# See versioning rule:
|
||||
# http://www.gnu.org/software/libtool/manual/html_node/Updating-version-info.html
|
||||
|
|
|
@ -25,7 +25,7 @@ dnl Do not change user variables!
|
|||
dnl http://www.gnu.org/software/automake/manual/html_node/Flag-Variables-Ordering.html
|
||||
|
||||
AC_PREREQ(2.61)
|
||||
AC_INIT([nghttp2], [1.35.0], [t-tujikawa@users.sourceforge.net])
|
||||
AC_INIT([nghttp2], [1.35.1], [t-tujikawa@users.sourceforge.net])
|
||||
AC_CONFIG_AUX_DIR([.])
|
||||
AC_CONFIG_MACRO_DIR([m4])
|
||||
AC_CONFIG_HEADERS([config.h])
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH "H2LOAD" "1" "Nov 23, 2018" "1.35.0" "nghttp2"
|
||||
.TH "H2LOAD" "1" "Dec 10, 2018" "1.35.1" "nghttp2"
|
||||
.SH NAME
|
||||
h2load \- HTTP/2 benchmarking tool
|
||||
.
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH "NGHTTP" "1" "Nov 23, 2018" "1.35.0" "nghttp2"
|
||||
.TH "NGHTTP" "1" "Dec 10, 2018" "1.35.1" "nghttp2"
|
||||
.SH NAME
|
||||
nghttp \- HTTP/2 client
|
||||
.
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH "NGHTTPD" "1" "Nov 23, 2018" "1.35.0" "nghttp2"
|
||||
.TH "NGHTTPD" "1" "Dec 10, 2018" "1.35.1" "nghttp2"
|
||||
.SH NAME
|
||||
nghttpd \- HTTP/2 server
|
||||
.
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
.\" Man page generated from reStructuredText.
|
||||
.
|
||||
.TH "NGHTTPX" "1" "Nov 23, 2018" "1.35.0" "nghttp2"
|
||||
.TH "NGHTTPX" "1" "Dec 10, 2018" "1.35.1" "nghttp2"
|
||||
.SH NAME
|
||||
nghttpx \- HTTP/2 proxy
|
||||
.
|
||||
|
|
|
@ -220,9 +220,16 @@ const RNode *match_partial(bool *pattern_is_wildcard, const RNode *node,
|
|||
return node;
|
||||
}
|
||||
|
||||
// The last '/' handling, see below.
|
||||
node = find_next_node(node, '/');
|
||||
if (node != nullptr && node->index != -1 && node->len == 1) {
|
||||
return node;
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// The last '/' handling, see below.
|
||||
if (node->index != -1 && offset + n + 1 == node->len &&
|
||||
node->s[node->len - 1] == '/') {
|
||||
return node;
|
||||
|
@ -265,6 +272,13 @@ const RNode *match_partial(bool *pattern_is_wildcard, const RNode *node,
|
|||
return node;
|
||||
}
|
||||
|
||||
// The last '/' handling, see below.
|
||||
node = find_next_node(node, '/');
|
||||
if (node != nullptr && node->index != -1 && node->len == 1) {
|
||||
*pattern_is_wildcard = false;
|
||||
return node;
|
||||
}
|
||||
|
||||
return found_node;
|
||||
}
|
||||
|
||||
|
|
|
@ -45,6 +45,9 @@ void test_shrpx_router_match(void) {
|
|||
{StringRef::from_lit("www.nghttp2.org/alpha/"), 4},
|
||||
{StringRef::from_lit("/alpha"), 5},
|
||||
{StringRef::from_lit("example.com/alpha/"), 6},
|
||||
{StringRef::from_lit("nghttp2.org/alpha/bravo2/"), 7},
|
||||
{StringRef::from_lit("www2.nghttp2.org/alpha/"), 8},
|
||||
{StringRef::from_lit("www2.nghttp2.org/alpha2/"), 9},
|
||||
};
|
||||
|
||||
Router router;
|
||||
|
@ -84,6 +87,13 @@ void test_shrpx_router_match(void) {
|
|||
idx = router.match(StringRef::from_lit("nghttp2.org"),
|
||||
StringRef::from_lit("/alpha/bravo"));
|
||||
|
||||
CU_ASSERT(3 == idx);
|
||||
|
||||
idx = router.match(StringRef::from_lit("www2.nghttp2.org"),
|
||||
StringRef::from_lit("/alpha"));
|
||||
|
||||
CU_ASSERT(8 == idx);
|
||||
|
||||
idx = router.match(StringRef{}, StringRef::from_lit("/alpha"));
|
||||
|
||||
CU_ASSERT(5 == idx);
|
||||
|
|
Loading…
Reference in New Issue