diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2009-11-30 16:48:49 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2009-11-30 16:48:49 +0100 |
commit | 954308c949e3bb9ee0f08e697122833bbb5c87ac (patch) | |
tree | 719cee4bc2f1b4c8ed27660e2e116327921c7bd6 /lib | |
parent | 49c4d359ff6d5332f60c090ad2c26a9a39086014 (diff) | |
download | abrt-954308c949e3bb9ee0f08e697122833bbb5c87ac.tar.gz abrt-954308c949e3bb9ee0f08e697122833bbb5c87ac.tar.xz abrt-954308c949e3bb9ee0f08e697122833bbb5c87ac.zip |
fixes on top of AutoReportUIDs change. run tested
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Utils/parse_release.cpp | 4 | ||||
-rw-r--r-- | lib/Utils/xfuncs.cpp | 8 |
2 files changed, 5 insertions, 7 deletions
diff --git a/lib/Utils/parse_release.cpp b/lib/Utils/parse_release.cpp index b96cab76..8a106b69 100644 --- a/lib/Utils/parse_release.cpp +++ b/lib/Utils/parse_release.cpp @@ -11,7 +11,7 @@ void parse_release(const char *pRelease, string& pProduct, string& pVersion) { pProduct = "Fedora"; pVersion = "rawhide"; - VERB3 log("%s:Version is '%s' and product is '%s'",__func__, pVersion.c_str(), pProduct.c_str()); + VERB3 log("%s: version:'%s' product:'%s'", __func__, pVersion.c_str(), pProduct.c_str()); return; } if (strstr(pRelease, "Fedora")) @@ -36,5 +36,5 @@ void parse_release(const char *pRelease, string& pProduct, string& pVersion) } space++; } - VERB3 log("%s:Version is '%s' and product is '%s'",__func__, pVersion.c_str(), pProduct.c_str()); + VERB3 log("%s: version:'%s' product:'%s'", __func__, pVersion.c_str(), pProduct.c_str()); } diff --git a/lib/Utils/xfuncs.cpp b/lib/Utils/xfuncs.cpp index c4b6dd6b..583171f7 100644 --- a/lib/Utils/xfuncs.cpp +++ b/lib/Utils/xfuncs.cpp @@ -369,13 +369,11 @@ bool string_to_bool(const char *s) return false; } -bool getuidbyname(const char* login, uid_t *uid) +uid_t getuidbyname(const char* login) { struct passwd* pwd = getpwnam(login); if (pwd == NULL) - return false; + return -1; - *uid = pwd->pw_uid; - return true; + return pwd->pw_uid; } - |