зеркало из https://github.com/mozilla/pjs.git
not part of the build yet.
This commit is contained in:
Родитель
d3c33f2bc8
Коммит
cf899b43b5
|
@ -94,14 +94,20 @@ nsUserInfo::GetDomain(char * *aDomain)
|
|||
nsresult rv = NS_ERROR_FAILURE;
|
||||
|
||||
struct utsname buf;
|
||||
|
||||
char *domainname = nsnull;
|
||||
|
||||
if (uname(&buf)) {
|
||||
return rv;
|
||||
}
|
||||
|
||||
|
||||
if (buf.__domainname && nsCRT::strlen(buf.__domainname)) {
|
||||
*aDomain = nsCRT::strdup(buf.__domainname);
|
||||
#if 1
|
||||
domainname = buf.__domainname;
|
||||
#else
|
||||
domainname = buf.domainname;
|
||||
#endif
|
||||
|
||||
if (domainname && nsCRT::strlen(domainname)) {
|
||||
*aDomain = nsCRT::strdup(domainname);
|
||||
rv = NS_OK;
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -94,14 +94,20 @@ nsUserInfo::GetDomain(char * *aDomain)
|
|||
nsresult rv = NS_ERROR_FAILURE;
|
||||
|
||||
struct utsname buf;
|
||||
|
||||
char *domainname = nsnull;
|
||||
|
||||
if (uname(&buf)) {
|
||||
return rv;
|
||||
}
|
||||
|
||||
|
||||
if (buf.__domainname && nsCRT::strlen(buf.__domainname)) {
|
||||
*aDomain = nsCRT::strdup(buf.__domainname);
|
||||
#if 1
|
||||
domainname = buf.__domainname;
|
||||
#else
|
||||
domainname = buf.domainname;
|
||||
#endif
|
||||
|
||||
if (domainname && nsCRT::strlen(domainname)) {
|
||||
*aDomain = nsCRT::strdup(domainname);
|
||||
rv = NS_OK;
|
||||
}
|
||||
else {
|
||||
|
|
Загрузка…
Ссылка в новой задаче