Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
nghttp2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
nghttp2
Commits
b5e5972c
Commit
b5e5972c
authored
Sep 12, 2021
by
Tatsuhiro Tsujikawa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update doc
parent
525d59fd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
src/util.h
src/util.h
+5
-3
No files found.
src/util.h
View file @
b5e5972c
...
@@ -762,6 +762,11 @@ std::string format_duration(const std::chrono::microseconds &u);
...
@@ -762,6 +762,11 @@ std::string format_duration(const std::chrono::microseconds &u);
// Just like above, but this takes |t| as seconds.
// Just like above, but this takes |t| as seconds.
std
::
string
format_duration
(
double
t
);
std
::
string
format_duration
(
double
t
);
// The maximum buffer size including terminal NULL to store the result
// of make_hostport.
constexpr
size_t
max_hostport
=
NI_MAXHOST
+
/* [] for IPv6 */
2
+
/* : */
1
+
/* port */
5
+
/* terminal NULL */
1
;
// Just like make_http_hostport(), but doesn't treat 80 and 443
// Just like make_http_hostport(), but doesn't treat 80 and 443
// specially.
// specially.
StringRef
make_hostport
(
BlockAllocator
&
balloc
,
const
StringRef
&
host
,
StringRef
make_hostport
(
BlockAllocator
&
balloc
,
const
StringRef
&
host
,
...
@@ -798,9 +803,6 @@ StringRef make_hostport(OutputIt first, const StringRef &host, uint16_t port) {
...
@@ -798,9 +803,6 @@ StringRef make_hostport(OutputIt first, const StringRef &host, uint16_t port) {
StringRef
make_http_hostport
(
BlockAllocator
&
balloc
,
const
StringRef
&
host
,
StringRef
make_http_hostport
(
BlockAllocator
&
balloc
,
const
StringRef
&
host
,
uint16_t
port
);
uint16_t
port
);
constexpr
size_t
max_hostport
=
NI_MAXHOST
+
/* [] for IPv6 */
2
+
/* : */
1
+
/* port */
5
+
/* terminal NUL */
1
;
template
<
typename
OutputIt
>
template
<
typename
OutputIt
>
StringRef
make_http_hostport
(
OutputIt
first
,
const
StringRef
&
host
,
StringRef
make_http_hostport
(
OutputIt
first
,
const
StringRef
&
host
,
uint16_t
port
)
{
uint16_t
port
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment