aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp
diff options
context:
space:
mode:
authordimaandreev <dimaandreev@yandex-team.ru>2022-02-10 16:49:30 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:49:30 +0300
commit2ed758579191810ed2ee20ed5d3d3087de7ad1ff (patch)
tree5d5cb817648f650d76cf1076100726fd9b8448e8 /library/cpp
parente7b1f21afb7d922ce8aff97a44f7f5385d33051f (diff)
downloadydb-2ed758579191810ed2ee20ed5d3d3087de7ad1ff.tar.gz
Restoring authorship annotation for <dimaandreev@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'library/cpp')
-rw-r--r--library/cpp/tvmauth/client/misc/api/threaded_updater.cpp2
-rw-r--r--library/cpp/tvmauth/client/misc/disk_cache.cpp14
-rw-r--r--library/cpp/tvmauth/src/ut/service_ut.cpp2
-rw-r--r--library/cpp/tvmauth/src/ut/user_ut.cpp2
4 files changed, 10 insertions, 10 deletions
diff --git a/library/cpp/tvmauth/client/misc/api/threaded_updater.cpp b/library/cpp/tvmauth/client/misc/api/threaded_updater.cpp
index dea915d8a2..a7df49c05d 100644
--- a/library/cpp/tvmauth/client/misc/api/threaded_updater.cpp
+++ b/library/cpp/tvmauth/client/misc/api/threaded_updater.cpp
@@ -162,7 +162,7 @@ namespace NTvmAuth::NTvmApi {
}
RetrySettingsFilepath_ = path + "retry_settings";
- } else {
+ } else {
LogInfo("Disk cache disabled. Please set disk cache directory in settings for best reliability");
}
}
diff --git a/library/cpp/tvmauth/client/misc/disk_cache.cpp b/library/cpp/tvmauth/client/misc/disk_cache.cpp
index 7f991f6e56..3c01be4a83 100644
--- a/library/cpp/tvmauth/client/misc/disk_cache.cpp
+++ b/library/cpp/tvmauth/client/misc/disk_cache.cpp
@@ -10,7 +10,7 @@
#include <util/stream/file.h>
#include <util/stream/str.h>
#include <util/system/fs.h>
-#include <util/system/sysstat.h>
+#include <util/system/sysstat.h>
#include <util/system/tempfile.h>
#include <exception>
@@ -122,12 +122,12 @@ namespace NTvmAuth {
try {
{
- if (NFs::Exists(Filename_)) {
- Chmod(Filename_.c_str(),
- S_IRUSR | S_IWUSR); // 600
- }
-
- TFile file(Filename_, CreateAlways | WrOnly | Seq | AWUser | ARUser);
+ if (NFs::Exists(Filename_)) {
+ Chmod(Filename_.c_str(),
+ S_IRUSR | S_IWUSR); // 600
+ }
+
+ TFile file(Filename_, CreateAlways | WrOnly | Seq | AWUser | ARUser);
file.Flock(LOCK_EX | LOCK_NB);
TFileOutput output(file);
diff --git a/library/cpp/tvmauth/src/ut/service_ut.cpp b/library/cpp/tvmauth/src/ut/service_ut.cpp
index c9968104e1..5b6b5143bd 100644
--- a/library/cpp/tvmauth/src/ut/service_ut.cpp
+++ b/library/cpp/tvmauth/src/ut/service_ut.cpp
@@ -115,7 +115,7 @@ Y_UNIT_TEST_SUITE_IMPLEMENTATION(ServiceTestSuite) {
Y_UNIT_TEST(TicketProtoTest) {
ticket2::Ticket protobufTicket;
- UNIT_ASSERT(protobufTicket.ParseFromString(NUtils::Base64url2bin(SERVICE_TICKET_PROTOBUF)));
+ UNIT_ASSERT(protobufTicket.ParseFromString(NUtils::Base64url2bin(SERVICE_TICKET_PROTOBUF)));
TTestServiceTicketImpl checkedTicket(ETicketStatus::Ok, std::move(protobufTicket));
UNIT_ASSERT_EQUAL(ETicketStatus::Ok, checkedTicket.GetStatus());
UNIT_ASSERT_VALUES_EQUAL(std::numeric_limits<time_t>::max(), checkedTicket.GetExpirationTime());
diff --git a/library/cpp/tvmauth/src/ut/user_ut.cpp b/library/cpp/tvmauth/src/ut/user_ut.cpp
index 31629aaa9a..c040e94974 100644
--- a/library/cpp/tvmauth/src/ut/user_ut.cpp
+++ b/library/cpp/tvmauth/src/ut/user_ut.cpp
@@ -133,7 +133,7 @@ Y_UNIT_TEST_SUITE_IMPLEMENTATION(UserTestSuite) {
Y_UNIT_TEST(TicketProtoTest) {
ticket2::Ticket protobufTicket;
- UNIT_ASSERT(protobufTicket.ParseFromString(NUtils::Base64url2bin(USER_TICKET_PROTOBUF)));
+ UNIT_ASSERT(protobufTicket.ParseFromString(NUtils::Base64url2bin(USER_TICKET_PROTOBUF)));
TTestUserTicketImpl userTicket(ETicketStatus::Ok, std::move(protobufTicket));
UNIT_ASSERT_EQUAL(ETicketStatus::Ok, userTicket.GetStatus());
UNIT_ASSERT_EQUAL(std::numeric_limits<time_t>::max(), userTicket.GetExpirationTime());