aboutsummaryrefslogtreecommitdiffstats
path: root/util/system/user.cpp
diff options
context:
space:
mode:
authorVlad Yaroslavlev <vladon@vladon.com>2022-02-10 16:46:23 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:46:23 +0300
commit706b83ed7de5a473436620367af31fc0ceecde07 (patch)
tree103305d30dec77e8f6367753367f59b3cd68f9f1 /util/system/user.cpp
parent918e8a1574070d0ec733f0b76cfad8f8892ad2e5 (diff)
downloadydb-706b83ed7de5a473436620367af31fc0ceecde07.tar.gz
Restoring authorship annotation for Vlad Yaroslavlev <vladon@vladon.com>. Commit 1 of 2.
Diffstat (limited to 'util/system/user.cpp')
-rw-r--r--util/system/user.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/util/system/user.cpp b/util/system/user.cpp
index 83e89ea0a8..ac6772f458 100644
--- a/util/system/user.cpp
+++ b/util/system/user.cpp
@@ -13,7 +13,7 @@
#include <unistd.h>
#endif
-TString GetUsername() {
+TString GetUsername() {
for (const auto& var : {"LOGNAME", "USER", "LNAME", "USERNAME"}) {
TString val = GetEnv(var);
if (val) {
@@ -32,13 +32,13 @@ TString GetUsername() {
else
ythrow TSystemError(err) << " GetUserName failed";
} else {
- return TString(nameBuf.Data(), (size_t)(len - 1));
+ return TString(nameBuf.Data(), (size_t)(len - 1));
}
#elif defined(_bionic_)
const passwd* pwd = getpwuid(geteuid());
if (pwd) {
- return TString(pwd->pw_name);
+ return TString(pwd->pw_name);
}
ythrow TSystemError() << TStringBuf(" getpwuid failed");