Monero
Loading...
Searching...
No Matches
host.h
Go to the documentation of this file.
1#pragma once
2
3#include <string>
4
5namespace net
6{
12 inline void canonicalize_host(std::string& host) noexcept
13 {
14 for (char& c : host)
15 {
16 if ('A' <= c && c <= 'Z')
17 c = static_cast<char>(c - 'A' + 'a');
18 }
19 }
20}
Definition net_utils_base.h:59
void canonicalize_host(std::string &host) noexcept
Canonicalize a hostname by converting letters to lowercase.
Definition host.h:12