aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/string_utils/url/url.cpp
diff options
context:
space:
mode:
authoryazevnul <yazevnul@yandex-team.ru>2022-02-10 16:46:46 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:46:46 +0300
commit8cbc307de0221f84c80c42dcbe07d40727537e2c (patch)
tree625d5a673015d1df891e051033e9fcde5c7be4e5 /library/cpp/string_utils/url/url.cpp
parent30d1ef3941e0dc835be7609de5ebee66958f215a (diff)
downloadydb-8cbc307de0221f84c80c42dcbe07d40727537e2c.tar.gz
Restoring authorship annotation for <yazevnul@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/string_utils/url/url.cpp')
-rw-r--r--library/cpp/string_utils/url/url.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/library/cpp/string_utils/url/url.cpp b/library/cpp/string_utils/url/url.cpp
index 85f4ac5d69..284842f831 100644
--- a/library/cpp/string_utils/url/url.cpp
+++ b/library/cpp/string_utils/url/url.cpp
@@ -124,7 +124,7 @@ TStringBuf CutSchemePrefix(const TStringBuf url) noexcept {
}
template <bool KeepPort>
-static inline TStringBuf GetHostAndPortImpl(const TStringBuf url) {
+static inline TStringBuf GetHostAndPortImpl(const TStringBuf url) {
TStringBuf urlNoScheme = url;
urlNoScheme.Skip(GetHttpPrefixSize(url));
@@ -324,8 +324,8 @@ static bool HasPrefix(const TStringBuf url) noexcept {
TString AddSchemePrefix(const TString& url) {
return AddSchemePrefix(url, TStringBuf("http"));
-}
-
+}
+
TString AddSchemePrefix(const TString& url, TStringBuf scheme) {
if (HasPrefix(url)) {
return url;
@@ -347,7 +347,7 @@ static inline int x2c(unsigned char* x) {
static inline int Unescape(char* str) {
char *to, *from;
int dlen = 0;
- if ((str = strchr(str, '%')) == nullptr)
+ if ((str = strchr(str, '%')) == nullptr)
return dlen;
for (to = str, from = str; *from; from++, to++) {
if ((*to = *from) == '%') {
@@ -361,7 +361,7 @@ static inline int Unescape(char* str) {
return dlen;
}
-size_t NormalizeUrlName(char* dest, const TStringBuf source, size_t dest_size) {
+size_t NormalizeUrlName(char* dest, const TStringBuf source, size_t dest_size) {
if (source.empty() || source[0] == '?')
return strlcpy(dest, "/", dest_size);
size_t len = Min(dest_size - 1, source.length());
@@ -372,7 +372,7 @@ size_t NormalizeUrlName(char* dest, const TStringBuf source, size_t dest_size) {
return len;
}
-size_t NormalizeHostName(char* dest, const TStringBuf source, size_t dest_size, ui16 defport) {
+size_t NormalizeHostName(char* dest, const TStringBuf source, size_t dest_size, ui16 defport) {
size_t len = Min(dest_size - 1, source.length());
memcpy(dest, source.data(), len);
dest[len] = 0;