diff options
| author | luckygeck <[email protected]> | 2022-02-10 16:49:18 +0300 | 
|---|---|---|
| committer | Daniil Cherednik <[email protected]> | 2022-02-10 16:49:18 +0300 | 
| commit | cb691264f012c552bac85a9fe352baa062cd81dd (patch) | |
| tree | 5d5cb817648f650d76cf1076100726fd9b8448e8 | |
| parent | 48ea53d4c114c948fa16fee5ec66de2552c93471 (diff) | |
Restoring authorship annotation for <[email protected]>. Commit 2 of 2.
| -rw-r--r-- | library/cpp/getopt/small/modchooser.cpp | 6 | ||||
| -rw-r--r-- | library/cpp/getopt/small/modchooser.h | 4 | ||||
| -rw-r--r-- | library/cpp/http/fetch/httpfsm.rl6 | 6 | ||||
| -rw-r--r-- | library/cpp/http/fetch/httpfsm_ut.cpp | 28 | ||||
| -rw-r--r-- | library/cpp/http/fetch/library-htfetch_ut_hreflang_in.h | 6 | ||||
| -rw-r--r-- | library/cpp/http/fetch/library-htfetch_ut_hreflang_out.h | 4 | ||||
| -rw-r--r-- | library/cpp/http/fetch/ya.make | 4 | ||||
| -rw-r--r-- | library/cpp/json/json_writer.cpp | 2 | ||||
| -rw-r--r-- | library/cpp/messagebus/config/netaddr.cpp | 4 | ||||
| -rw-r--r-- | library/cpp/messagebus/event_loop.cpp | 2 | ||||
| -rw-r--r-- | library/cpp/messagebus/rain_check/http/client.cpp | 22 | ||||
| -rw-r--r-- | library/cpp/messagebus/rain_check/http/client.h | 12 | ||||
| -rw-r--r-- | library/cpp/messagebus/rain_check/http/client_ut.cpp | 44 | ||||
| -rw-r--r-- | library/cpp/monlib/dynamic_counters/page.cpp | 8 | ||||
| -rw-r--r-- | library/cpp/monlib/dynamic_counters/page.h | 16 | ||||
| -rw-r--r-- | library/cpp/yson/node/node_builder.h | 2 | ||||
| -rw-r--r-- | library/cpp/yson/node/node_io.cpp | 4 | ||||
| -rw-r--r-- | util/thread/lfqueue.h | 16 | 
18 files changed, 95 insertions, 95 deletions
diff --git a/library/cpp/getopt/small/modchooser.cpp b/library/cpp/getopt/small/modchooser.cpp index 8b7cacd7eba..2fa5cfd0703 100644 --- a/library/cpp/getopt/small/modchooser.cpp +++ b/library/cpp/getopt/small/modchooser.cpp @@ -82,12 +82,12 @@ TModChooser::~TModChooser() = default;  void TModChooser::AddMode(const TString& mode, const TMainFunctionRawPtr func, const TString& description, bool hidden, bool noCompletion) {      AddMode(mode, TMainFunctionPtr(func), description, hidden, noCompletion); -}  +}  void TModChooser::AddMode(const TString& mode, const TMainFunctionRawPtrV func, const TString& description, bool hidden, bool noCompletion) {      AddMode(mode, TMainFunctionPtrV(func), description, hidden, noCompletion); -}  -  +} +  void TModChooser::AddMode(const TString& mode, const TMainFunctionPtr func, const TString& description, bool hidden, bool noCompletion) {      Wrappers.push_back(MakeHolder<PtrWrapper>(func));      AddMode(mode, Wrappers.back().Get(), description, hidden, noCompletion); diff --git a/library/cpp/getopt/small/modchooser.h b/library/cpp/getopt/small/modchooser.h index 7a7eb8ef236..0a8de6d50b5 100644 --- a/library/cpp/getopt/small/modchooser.h +++ b/library/cpp/getopt/small/modchooser.h @@ -6,8 +6,8 @@  #include <util/generic/string.h>  #include <util/generic/vector.h> -#include <functional>  -  +#include <functional> +  //! Mode function with vector of cli arguments.  using TMainFunctionPtrV = std::function<int(const TVector<TString>&)> ;  using TMainFunctionRawPtrV = int (*)(const TVector<TString>& argv); diff --git a/library/cpp/http/fetch/httpfsm.rl6 b/library/cpp/http/fetch/httpfsm.rl6 index c9f62144619..eab0328b187 100644 --- a/library/cpp/http/fetch/httpfsm.rl6 +++ b/library/cpp/http/fetch/httpfsm.rl6 @@ -322,7 +322,7 @@ action set_hreflang {          *(hreflangpos++) = ' ';          memcpy(hreflangpos, buf, buflen);          hreflangpos += buflen; -        *(hreflangpos) = 0;  +        *(hreflangpos) = 0;          hreflangspace -= len2;      }  } @@ -334,9 +334,9 @@ action start_lang {  action end_lang {      langlen = fpc - langstart;  } -hreflang_token = (token_char - ['])+;  +hreflang_token = (token_char - ['])+;  quote = ['"]?; #" -lang = hreflang_token >start_lang %end_lang;  +lang = hreflang_token >start_lang %end_lang;  hreflang = "link"i def '<' url '>' lws ";" lws      ( ( "rel"i lws '=' lws quote "alternate" quote lws ';' lws "hreflang"i lws '=' lws quote lang quote ) diff --git a/library/cpp/http/fetch/httpfsm_ut.cpp b/library/cpp/http/fetch/httpfsm_ut.cpp index faa3117c4e8..b018e80101b 100644 --- a/library/cpp/http/fetch/httpfsm_ut.cpp +++ b/library/cpp/http/fetch/httpfsm_ut.cpp @@ -1,6 +1,6 @@  #include "httpfsm.h" -#include "library-htfetch_ut_hreflang_in.h"  -#include "library-htfetch_ut_hreflang_out.h"  +#include "library-htfetch_ut_hreflang_in.h" +#include "library-htfetch_ut_hreflang_out.h"  #include <util/generic/ptr.h>  #include <library/cpp/charset/doccodes.h> @@ -59,7 +59,7 @@ public:      void TestXRobotsTagAllowsMultiline();      void TestRelCanonical();      void TestHreflang(); -    void TestHreflangOnLongInput();  +    void TestHreflangOnLongInput();      void TestMimeType();      void TestRepeatedContentEncoding();  }; @@ -398,18 +398,18 @@ void THttpHeaderParserTestSuite::TestHreflang() {      TestFinish();  } -void THttpHeaderParserTestSuite::TestHreflangOnLongInput() {  -    TestStart();  -    THttpHeader httpHeader;  -    httpHeaderParser->Init(&httpHeader);  -    TStringBuf testInput(hreflang_ut_in);  -    TStringBuf testOut(hreflang_ut_out);  +void THttpHeaderParserTestSuite::TestHreflangOnLongInput() { +    TestStart(); +    THttpHeader httpHeader; +    httpHeaderParser->Init(&httpHeader); +    TStringBuf testInput(hreflang_ut_in); +    TStringBuf testOut(hreflang_ut_out);      i32 result = httpHeaderParser->Execute(testInput.data(), testInput.size()); -    UNIT_ASSERT_VALUES_EQUAL(result, 2);  -    UNIT_ASSERT_VALUES_EQUAL(httpHeader.hreflangs, testOut);  -    TestFinish();  -}  -  +    UNIT_ASSERT_VALUES_EQUAL(result, 2); +    UNIT_ASSERT_VALUES_EQUAL(httpHeader.hreflangs, testOut); +    TestFinish(); +} +  void THttpHeaderParserTestSuite::TestRelCanonical() {      TestStart();      THttpHeader httpHeader; diff --git a/library/cpp/http/fetch/library-htfetch_ut_hreflang_in.h b/library/cpp/http/fetch/library-htfetch_ut_hreflang_in.h index e92a5e767e2..0df89bdc799 100644 --- a/library/cpp/http/fetch/library-htfetch_ut_hreflang_in.h +++ b/library/cpp/http/fetch/library-htfetch_ut_hreflang_in.h @@ -1,6 +1,6 @@ -#pragma once  -  -char hreflang_ut_in[] = "HTTP/1.1 200 OK\n"  +#pragma once + +char hreflang_ut_in[] = "HTTP/1.1 200 OK\n"                          "Date: Thu, 15 Nov 2012 22:38:28 GMT\n"                          "Server: Apache/2\n"                          "X-Powered-By: PHP/5.2.17\n" diff --git a/library/cpp/http/fetch/library-htfetch_ut_hreflang_out.h b/library/cpp/http/fetch/library-htfetch_ut_hreflang_out.h index 1154f4aacdd..bef8bacff5b 100644 --- a/library/cpp/http/fetch/library-htfetch_ut_hreflang_out.h +++ b/library/cpp/http/fetch/library-htfetch_ut_hreflang_out.h @@ -1,3 +1,3 @@ -#pragma once  -  +#pragma once +  char hreflang_ut_out[] = "zh-CN http://www.forexticket.cn.com/zh/currency/converter-EEK-XAG\tzh-TW http://www.forexticket.tw/zh/currency/converter-EEK-XAG\tzh-HK http://www.forexticket.hk/zh/currency/converter-EEK-XAG\tzh-SG http://www.forexticket.sg/zh/currency/converter-EEK-XAG\thi-IN http://www.forexticket.in/hi/currency/converter-EEK-XAG\thi-FJ http://www.forexticket.com.fj/hi/currency/converter-EEK-XAG\ten-IN http://www.forexticket.in/en/currency/converter-EEK-XAG\ten-US http://www.forexticket.us/en/currency/converter-EEK-XAG\ten-PK http://www.forexticket.com.pk/en/currency/converter-EEK-XAG\ten-BD http://www.forexticket-bd.com/en/currency/converter-EEK-XAG\ten-NG http://www.forexticket-ng.com/en/currency/converter-EEK-XAG\ten-GB http://www.forexticket.co.uk/en/currency/converter-EEK-XAG\ten-ZA http://www.forexticket.co.za/en/currency/converter-EEK-XAG\ten-KE http://www.forexticket.co.ke/en/currency/converter-EEK-XAG\ten-CA http://www.forexticket.com/en/currency/converter-EEK-XAG\ten-GH http://www.forexticket-gh.com/en/currency/converter-EEK-XAG\ten-AU http://www.forexticket.biz/en/currency/converter-EEK-XAG\ten-CM http://www.forexticket.cm/en/currency/converter-EEK-XAG\ten-KH http://www.forexticket-kh.com/en/currency/converter-EEK-XAG\ten-HK http://www.forexticket.hk/en/currency/converter-EEK-XAG\ten-LA http://www.forexticket.la/en/currency/converter-EEK-XAG\ten-SG http://www.forexticket.sg/en/currency/converter-EEK-XAG\ten-NZ http://www.forexticket.co.nz/en/currency/converter-EEK-XAG\ten-PR http://www.forexticket.com.pr/en/currency/converter-EEK-XAG\ten-FJ http://www.forexticket.com.fj/en/currency/converter-EEK-XAG\tes-US http://www.forexticket.us/es/cambio/divisas-EEK-XAG\tes-MX http://www.forexticket.mx/es/cambio/divisas-EEK-XAG\tes-CO http://www.forexticket.co/es/cambio/divisas-EEK-XAG\tes-AR http://www.forexticket.com.ar/es/cambio/divisas-EEK-XAG\tes-PE http://www.forexticket-pe.com/es/cambio/divisas-EEK-XAG\tes-VE http://www.forexticket.co.ve/es/cambio/divisas-EEK-XAG\tes-CL http://www.forexticket.cl/es/cambio/divisas-EEK-XAG\tes-EC http://www.forexticket.ec/es/cambio/divisas-EEK-XAG\tes-GT http://www.forexticket.com.gt/es/cambio/divisas-EEK-XAG\tes-BO http://www.forexticket.bo/es/cambio/divisas-EEK-XAG\tes-HN http://www.forexticket.hn/es/cambio/divisas-EEK-XAG\tes-PY http://www.forexticket.com.py/es/cambio/divisas-EEK-XAG\tes-ES http://www.forexticket.es/es/cambio/divisas-EEK-XAG\tes-SV http://www.forexticket.com.sv/es/cambio/divisas-EEK-XAG\tes-NI http://www.forexticket.com.ni/es/cambio/divisas-EEK-XAG\tes-CR http://www.forexticket.co.cr/es/cambio/divisas-EEK-XAG\tes-PR http://www.forexticket.com.pr/es/cambio/divisas-EEK-XAG\tes-UY http://www.forexticket.com.uy/es/cambio/divisas-EEK-XAG\tes-PA http://www.forexticket.com.pa/es/cambio/divisas-EEK-XAG\tid-ID http://www.forexticket.asia.com/id/currency/converter-EEK-XAG\tpt-BR http://www.forexticket.com.br/pt/moeda/conversor-EEK-XAG\tpt-MZ http://www.forexticket-mz.com/pt/moeda/conversor-EEK-XAG\tpt-PT http://www.forexticket.com.pt/pt/moeda/conversor-EEK-XAG\tpt-TL http://www.forexticket.tl/pt/moeda/conversor-EEK-XAG\tru-RU http://www.forexticket.ru/ru/currency/converter-EEK-XAG\tru-KZ http://www.forexticket-kz.com/ru/currency/converter-EEK-XAG\tru-TJ http://www.forexticket-tj.com/ru/currency/converter-EEK-XAG\tru-KG http://www.forexticket-kg.com/ru/currency/converter-EEK-XAG\tru-GE http://www.forexticket-ge.com/ru/currency/converter-EEK-XAG\tru-MN http://www.forexticket.mn/ru/currency/converter-EEK-XAG\tja-JP http://www.forexticket.jp/ja/currency/converter-EEK-XAG\ttl-PH http://www.forexticket-ph.com/tl/currency/converter-EEK-XAG\tvi-VN http://www.forexticket.vn/vi/currency/converter-EEK-XAG\tde-DE http://www.forexticket.de/de/waehrungsumrechner/devisen-EEK-XAG\tde-BE http://www.forexticket.be/de/waehrungsumrechner/devisen-EEK-XAG\tde-AT http://www.forexticket.at/de/waehrungsumrechner/devisen-EEK-XAG\tde-CH http://www.forexticket.ch/de/waehrungsumrechner/devisen-EEK-XAG\tde-LU http://www.forexticket.lu/de/waehrungsumrechner/devisen-EEK-XAG\tde-LI http://www.forexticket.li/de/waehrungsumrechner/devisen-EEK-XAG\tar-EG http://www.forexticket-eg.com/ar/currency/converter-EEK-XAG\tar-DZ http://www.forexticket-dz.com/ar/currency/converter-EEK-XAG\tar-MA http://www.forexticket-ma.com/ar/currency/converter-EEK-XAG\tar-IQ http://www.forexticket-iq.com/ar/currency/converter-EEK-XAG\tar-SA http://www.forexticket-sa.com/ar/currency/converter-EEK-XAG\tar-SY http://www.forexticket-sy.com/ar/currency/converter-EEK-XAG\tar-TN http://www.forexticket-tn.com/ar/currency/converter-EEK-XAG\tar-TD http://www.forexticket-td.com/ar/currency/converter-EEK-XAG\tar-SO http://www.forexticket-so.com/ar/currency/converter-EEK-XAG\tar-IL http://www.forexticket.co.il/ar/currency/converter-EEK-XAG\tar-JO http://www.forexticket-jo.com/ar/currency/converter-EEK-XAG\tar-AE http://www.forexticket.ae/ar/currency/converter-EEK-XAG\tar-LB http://www.forexticket-lb.com/ar/currency/converter-EEK-XAG\tar-OM http://www.forexticket-om.com/ar/currency/converter-EEK-XAG\tar-KW http://www.forexticket-kw.com/ar/currency/converter-EEK-XAG\ttr-TR http://www.forexticket-tr.com/tr/currency/converter-EEK-XAG\ttr-BG http://www.forexticket-bg.com/tr/currency/converter-EEK-XAG\ttr-CY http://www.forexticket-cy.com/tr/currency/converter-EEK-XAG\tfa-IR http://www.forexticket.ir/fa/currency/converter-EEK-XAG\tfa-AF http://www.forexticket.af/fa/currency/converter-EEK-XAG\tfr-CD http://www.forexticket.cd/fr/conversion/monnaie-EEK-XAG\tfr-FR http://www.forexticket.fr/fr/conversion/monnaie-EEK-XAG\tfr-CA http://www.forexticket.com/fr/conversion/monnaie-EEK-XAG\tfr-MG http://www.forexticket.mg/fr/conversion/monnaie-EEK-XAG\tfr-CM http://www.forexticket.cm/fr/conversion/monnaie-EEK-XAG\tfr-KH http://www.forexticket-kh.com/fr/conversion/monnaie-EEK-XAG\tfr-ML http://www.forexticket-ml.com/fr/conversion/monnaie-EEK-XAG\tfr-SN http://www.forexticket-sn.com/fr/conversion/monnaie-EEK-XAG\tfr-TN http://www.forexticket-tn.com/fr/conversion/monnaie-EEK-XAG\tfr-TD http://www.forexticket-td.com/fr/conversion/monnaie-EEK-XAG\tfr-BE http://www.forexticket.be/fr/conversion/monnaie-EEK-XAG\tfr-GN http://www.forexticket-gn.com/fr/conversion/monnaie-EEK-XAG\tfr-HT http://www.forexticket.ht/fr/conversion/monnaie-EEK-XAG\tfr-CH http://www.forexticket.ch/fr/conversion/monnaie-EEK-XAG\tfr-LA http://www.forexticket.la/fr/conversion/monnaie-EEK-XAG\tfr-LU http://www.forexticket.lu/fr/conversion/monnaie-EEK-XAG\tth-TH http://www.forexticket-th.com/th/currency/converter-EEK-XAG\tcy-GB http://www.forexticket.co.uk/cy/currency/converter-EEK-XAG\tga-GB http://www.forexticket.co.uk/ga/currency/converter-EEK-XAG\tit-IT http://www.forexticket.it/it/convertitore/valuta-EEK-XAG\tit-CH http://www.forexticket.ch/it/convertitore/valuta-EEK-XAG\taf-ZA http://www.forexticket.co.za/af/currency/converter-EEK-XAG\tko-KR http://www.forexticket.kr/ko/currency/converter-EEK-XAG\tuk-UA http://www.forexticket-ua.com/uk/currency/converter-EEK-XAG\tsw-TZ http://www.forexticket-tz.com/sw/currency/converter-EEK-XAG\tsw-KE http://www.forexticket.co.ke/sw/currency/converter-EEK-XAG\tpl-PL http://www.forexticket.pl/pl/currency/converter-EEK-XAG\tms-MY http://www.forexticket.com.my/ms/currency/converter-EEK-XAG\tms-SG http://www.forexticket.sg/ms/currency/converter-EEK-XAG\tro-RO http://www.forexticket.ro/ro/currency/converter-EEK-XAG\tnl-NL http://www.forexticket.nl/nl/currency/converter-EEK-XAG\tnl-BE http://www.forexticket.be/nl/currency/converter-EEK-XAG\tel-GR http://www.forexticket.gr/el/currency/converter-EEK-XAG\tel-AL http://www.forexticket-al.com/el/currency/converter-EEK-XAG\tel-CY http://www.forexticket-cy.com/el/currency/converter-EEK-XAG\tcs-CZ http://www.forexticket.cz/cs/currency/converter-EEK-XAG\thu-HU http://www.forexticket.hu/hu/currency/converter-EEK-XAG\tsv-SE http://www.forexticket.se/sv/currency/converter-EEK-XAG\tsv-FI http://www.forexticket.eu/sv/currency/converter-EEK-XAG\tiw-IL http://www.forexticket.co.il/iw/currency/converter-EEK-XAG\tyi-IL http://www.forexticket.co.il/yi/currency/converter-EEK-XAG\tbg-BG http://www.forexticket-bg.com/bg/currency/converter-EEK-XAG\tca-ES http://www.forexticket.es/ca/currency/converter-EEK-XAG\tgl-ES http://www.forexticket.es/gl/currency/converter-EEK-XAG\tda-DK http://www.forexticket.dk/da/currency/converter-EEK-XAG\tfi-FI http://www.forexticket.eu/fi/currency/converter-EEK-XAG\thr-HR http://www.forexticket-hr.com/hr/currency/converter-EEK-XAG\tsr-HR http://www.forexticket-hr.com/sr/currency/converter-EEK-XAG\tsr-ME http://www.forexticket.me/sr/currency/converter-EEK-XAG\tlt-LT http://www.forexticket.lt/lt/currency/converter-EEK-XAG\tsq-AL http://www.forexticket-al.com/sq/currency/converter-EEK-XAG\tlv-LV http://www.forexticket.lv/lv/currency/converter-EEK-XAG\tet-EE http://www.forexticket.co.ee/et/currency/converter-EEK-XAG"; diff --git a/library/cpp/http/fetch/ya.make b/library/cpp/http/fetch/ya.make index 04b66d3a267..77371274639 100644 --- a/library/cpp/http/fetch/ya.make +++ b/library/cpp/http/fetch/ya.make @@ -29,8 +29,8 @@ SRCS(      sockhandler.h  ) -GENERATE_ENUM_SERIALIZATION(httpheader.h)  -  +GENERATE_ENUM_SERIALIZATION(httpheader.h) +  SET(RAGEL6_FLAGS -CF1)  END() diff --git a/library/cpp/json/json_writer.cpp b/library/cpp/json/json_writer.cpp index 18b5f03ca30..3d058bae360 100644 --- a/library/cpp/json/json_writer.cpp +++ b/library/cpp/json/json_writer.cpp @@ -49,7 +49,7 @@ namespace NJson {      void TJsonWriter::Flush() {          if (Out) {              Buf.FlushTo(Out); -        }  +        }      }      void TJsonWriter::OpenMap() { diff --git a/library/cpp/messagebus/config/netaddr.cpp b/library/cpp/messagebus/config/netaddr.cpp index bb670ca50e5..962ac538e27 100644 --- a/library/cpp/messagebus/config/netaddr.cpp +++ b/library/cpp/messagebus/config/netaddr.cpp @@ -27,8 +27,8 @@ namespace NBus {                  return AF_INET6;          }          Y_FAIL(); -    }  -  +    } +      class TNetworkAddressRef: private TNetworkAddress, public TAddrInfo {      public:          TNetworkAddressRef(const TNetworkAddress& na, const TAddrInfo& ai) diff --git a/library/cpp/messagebus/event_loop.cpp b/library/cpp/messagebus/event_loop.cpp index 9e0244cbac3..f685135bedd 100644 --- a/library/cpp/messagebus/event_loop.cpp +++ b/library/cpp/messagebus/event_loop.cpp @@ -3,7 +3,7 @@  #include "network.h"  #include "thread_extra.h" -#include <util/generic/hash.h>  +#include <util/generic/hash.h>  #include <util/network/pair.h>  #include <util/network/poller.h>  #include <util/system/event.h> diff --git a/library/cpp/messagebus/rain_check/http/client.cpp b/library/cpp/messagebus/rain_check/http/client.cpp index 0d2d717cc89..5ef5ceeece2 100644 --- a/library/cpp/messagebus/rain_check/http/client.cpp +++ b/library/cpp/messagebus/rain_check/http/client.cpp @@ -10,8 +10,8 @@  #include <util/generic/ptr.h>  #include <util/generic/strbuf.h> -#include <util/network/socket.h>  -#include <util/stream/str.h>  +#include <util/network/socket.h> +#include <util/stream/str.h>  namespace NRainCheck {      class THttpCallback: public NNeh::IOnRecv { @@ -66,11 +66,11 @@ namespace NRainCheck {      void THttpClientService::SendPost(TString addr, const TString& data, const THttpHeaders& headers, THttpFuture* future) {          Y_VERIFY(!!future, "future is NULL."); -  +          TTaskRunnerBase* current = TTaskRunnerBase::CurrentTask();          future->SetRunning(current);          future->Task = current; -  +          THolder<THttpCallback> callback(new THttpCallback(future));          NNeh::TServiceStatRef stat;          try { @@ -93,7 +93,7 @@ namespace NRainCheck {          TTaskRunnerBase* current = TTaskRunnerBase::CurrentTask();          future->SetRunning(current);          future->Task = current; -  +          THolder<THttpCallback> callback(new THttpCallback(future));          NNeh::TServiceStatRef stat;          try { @@ -107,11 +107,11 @@ namespace NRainCheck {              future->SetFail(THttpFuture::OtherError, err.AsStrBuf());          }      } -  +      bool THttpFuture::HasHttpCode() const {          return !!HttpCode; -    }  -  +    } +      bool THttpFuture::HasResponseBody() const {          return !!Response;      } @@ -121,7 +121,7 @@ namespace NRainCheck {          Y_ASSERT(HasHttpCode());          return static_cast<ui32>(*HttpCode); -    }  +    }      TString THttpFuture::GetResponseBody() const {          Y_ASSERT(IsDone()); @@ -149,6 +149,6 @@ namespace NRainCheck {          ErrorDescription = errorDescription;          Response.Destroy();          SetDone(); -    }  +    } -}  +} diff --git a/library/cpp/messagebus/rain_check/http/client.h b/library/cpp/messagebus/rain_check/http/client.h index 1d1e5005096..d4199c4c98d 100644 --- a/library/cpp/messagebus/rain_check/http/client.h +++ b/library/cpp/messagebus/rain_check/http/client.h @@ -10,8 +10,8 @@  #include <util/system/defaults.h>  #include <util/system/yassert.h> -class THttpHeaders;  -  +class THttpHeaders; +  namespace NNeh {      class IProtocol;      struct TResponse; @@ -28,14 +28,14 @@ namespace NRainCheck {              CantResolveNameError = 1,              BadHttpCodeError = 2, -  +              OtherError = 100          }; -  +      private:          friend class THttpCallback;          friend class THttpClientService; -  +      public:          THttpFuture();          ~THttpFuture() override; @@ -53,7 +53,7 @@ namespace NRainCheck {      private:          void SetDoneAndSchedule(TAutoPtr<NNeh::TResponse> response);          void SetFail(EError errorCode, const TStringBuf& errorDescription); -  +      private:          TTaskRunnerBase* Task;          TMaybe<HttpCodes> HttpCode; diff --git a/library/cpp/messagebus/rain_check/http/client_ut.cpp b/library/cpp/messagebus/rain_check/http/client_ut.cpp index 97a726af448..16281143911 100644 --- a/library/cpp/messagebus/rain_check/http/client_ut.cpp +++ b/library/cpp/messagebus/rain_check/http/client_ut.cpp @@ -43,7 +43,7 @@ namespace {      TString BuildServiceLocation(ui32 port) {          return Sprintf("http://*:%" PRIu32 "/%s", port, TEST_SERVICE.data());      } -  +      TString BuildPostServiceLocation(ui32 port) {          return Sprintf("post://*:%" PRIu32 "/%s", port + 1, TEST_SERVICE.data());      } @@ -64,7 +64,7 @@ namespace {              req->SendReply(response);          }      }; -  +      NNeh::IServicesRef RunServer(ui32 port, TSimpleServer& server) {          NNeh::IServicesRef runner = NNeh::CreateLoop();          runner->Add(BuildServiceLocation(port), server); @@ -75,7 +75,7 @@ namespace {              runner->ForkLoop(THR_POOL_SIZE);          } catch (...) {              Y_FAIL("Can't run server: %s", CurrentExceptionMessage().data()); -        }  +        }          return runner;      } @@ -94,7 +94,7 @@ namespace {              , ReqType(param.second)          {          } -  +          TContinueFunc Start() override {              switch (ReqType) {                  case RT_HTTP_GET: { @@ -104,7 +104,7 @@ namespace {                          Env->HttpClientService.Send(getRequest, Requests[i].Get());                      }                      break; -                }  +                }                  case RT_HTTP_POST: {                      TString servicePath = BuildPostServiceLocation(ServerPort);                      TStringInput headersText(TEST_POST_HEADERS); @@ -114,8 +114,8 @@ namespace {                          Env->HttpClientService.SendPost(servicePath, TEST_POST_PARAMS, headers, Requests[i].Get());                      }                      break; -                }  -            }  +                } +            }              return &THttpClientTask::GotReplies;          } @@ -154,25 +154,25 @@ Y_UNIT_TEST_SUITE(RainCheckHttpClient) {          NNeh::IServicesRef runner = RunServer(SERVER_PORT, server);          THttpClientEnv env; -        TIntrusivePtr<TSimpleTaskRunner> task = env.SpawnTask<THttpClientTask>(TTaskParam(SERVER_PORT, RT_HTTP_GET));  +        TIntrusivePtr<TSimpleTaskRunner> task = env.SpawnTask<THttpClientTask>(TTaskParam(SERVER_PORT, RT_HTTP_GET));          env.TestSync.WaitForAndIncrement(1);      } -  +      Y_UNIT_TEST(SimplePost) { -        // TODO: randomize port  -        if (!IsFixedPortTestAllowed()) {  -            return;  -        }  -  -        TSimpleServer server;  -        NNeh::IServicesRef runner = RunServer(SERVER_PORT, server);  -  -        THttpClientEnv env;  -        TIntrusivePtr<TSimpleTaskRunner> task = env.SpawnTask<THttpClientTask>(TTaskParam(SERVER_PORT, RT_HTTP_POST));  -  -        env.TestSync.WaitForAndIncrement(1);  -    }  +        // TODO: randomize port +        if (!IsFixedPortTestAllowed()) { +            return; +        } + +        TSimpleServer server; +        NNeh::IServicesRef runner = RunServer(SERVER_PORT, server); + +        THttpClientEnv env; +        TIntrusivePtr<TSimpleTaskRunner> task = env.SpawnTask<THttpClientTask>(TTaskParam(SERVER_PORT, RT_HTTP_POST)); + +        env.TestSync.WaitForAndIncrement(1); +    }      Y_UNIT_TEST(HttpCodeExtraction) {      // Find "request failed(" string, then copy len("HTTP/1.X NNN") chars and try to convert NNN to HTTP code. diff --git a/library/cpp/monlib/dynamic_counters/page.cpp b/library/cpp/monlib/dynamic_counters/page.cpp index d6f61d720bd..5124a47bb33 100644 --- a/library/cpp/monlib/dynamic_counters/page.cpp +++ b/library/cpp/monlib/dynamic_counters/page.cpp @@ -27,10 +27,10 @@ TMaybe<EFormat> ParseFormat(TStringBuf str) {  }  void TDynamicCountersPage::Output(NMonitoring::IMonHttpRequest& request) { -    if (OutputCallback) {  -        OutputCallback();  -    }  -  +    if (OutputCallback) { +        OutputCallback(); +    } +      TCountableBase::EVisibility visibility{          TCountableBase::EVisibility::Public      }; diff --git a/library/cpp/monlib/dynamic_counters/page.h b/library/cpp/monlib/dynamic_counters/page.h index a8323910e5a..1f0ef6a5eaf 100644 --- a/library/cpp/monlib/dynamic_counters/page.h +++ b/library/cpp/monlib/dynamic_counters/page.h @@ -6,7 +6,7 @@  #include <util/generic/ptr.h> -#include <functional>  +#include <functional>  namespace NMonitoring {      enum class EUnknownGroupPolicy { @@ -15,14 +15,14 @@ namespace NMonitoring {      };      struct TDynamicCountersPage: public TPreMonPage { -    public:  -        using TOutputCallback = std::function<void()>;  -  +    public: +        using TOutputCallback = std::function<void()>; +      private:          const TIntrusivePtr<TDynamicCounters> Counters; -        TOutputCallback OutputCallback;  +        TOutputCallback OutputCallback;          EUnknownGroupPolicy UnknownGroupPolicy {EUnknownGroupPolicy::Error}; -  +      private:          void HandleAbsentSubgroup(IMonHttpRequest& request); @@ -30,10 +30,10 @@ namespace NMonitoring {          TDynamicCountersPage(const TString& path,                               const TString& title,                               TIntrusivePtr<TDynamicCounters> counters, -                             TOutputCallback outputCallback = nullptr)  +                             TOutputCallback outputCallback = nullptr)              : TPreMonPage(path, title)              , Counters(counters) -            , OutputCallback(outputCallback)  +            , OutputCallback(outputCallback)          {          } diff --git a/library/cpp/yson/node/node_builder.h b/library/cpp/yson/node/node_builder.h index d8d9f6b0abc..69800016e09 100644 --- a/library/cpp/yson/node/node_builder.h +++ b/library/cpp/yson/node/node_builder.h @@ -3,7 +3,7 @@  #include "node.h"  #include <library/cpp/json/json_reader.h> -  +  #include <library/cpp/yson/consumer.h>  #include <util/generic/stack.h> diff --git a/library/cpp/yson/node/node_io.cpp b/library/cpp/yson/node/node_io.cpp index 1f7a3f9aa37..294a7f7217f 100644 --- a/library/cpp/yson/node/node_io.cpp +++ b/library/cpp/yson/node/node_io.cpp @@ -7,10 +7,10 @@  #include <library/cpp/yson/parser.h>  #include <library/cpp/yson/writer.h>  #include <library/cpp/yson/json/yson2json_adapter.h> -  +  #include <library/cpp/json/json_reader.h>  #include <library/cpp/json/json_value.h> -  +  #include <util/stream/input.h>  #include <util/stream/output.h>  #include <util/stream/str.h> diff --git a/util/thread/lfqueue.h b/util/thread/lfqueue.h index bda92551d73..ab523631e4f 100644 --- a/util/thread/lfqueue.h +++ b/util/thread/lfqueue.h @@ -393,14 +393,14 @@ public:          Y_UNUSED(t.Release());      } -    inline bool IsEmpty() {  -        return Queue.IsEmpty();  -    }  -  -    inline TCounter GetCounter() {  -        return Queue.GetCounter();  -    }  -  +    inline bool IsEmpty() { +        return Queue.IsEmpty(); +    } + +    inline TCounter GetCounter() { +        return Queue.GetCounter(); +    } +  private:      TLockFreeQueue<T*, TCounter> Queue;  };  | 
