Revert to a default login in case of an EMPTY_WRAPPED_STRING.

This commit is contained in:
Andrius Silinskas 2013-08-10 19:53:10 +01:00
parent d562bdf475
commit 055caebcf2

View file

@ -423,7 +423,7 @@ void set_wrap_login(bool wrap)
std::string login()
{
const std::string res = preferences::get("login");
if(res.empty()) {
if(res.empty() || res == EMPTY_WRAPPED_STRING) {
char* const login = getenv("USER");
if(login != NULL) {
return login;