Changeset 54702 in vbox for trunk/src/VBox
- Timestamp:
- Mar 9, 2015 5:25:28 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxService/VBoxServiceVMInfo.cpp
r53874 r54702 707 707 struct passwd *ppwEntry = getpwuid(uid); 708 708 if ( ppwEntry 709 && ppwEntry->pw_uid >= uid_min /* Only respect users, not daemons etc. */710 709 && ppwEntry->pw_name) 711 710 { 712 VBoxServiceVerbose(4, "ConsoleKit: session '%s' -> %s (uid: %RU32)\n", 713 *ppszCurSession, ppwEntry->pw_name, uid); 714 715 bool fFound = false; 716 for (uint32_t i = 0; i < cUsersInList && !fFound; i++) 717 fFound = strcmp(papszUsers[i], ppwEntry->pw_name) == 0; 718 719 if (!fFound) 711 if (ppwEntry->pw_uid >= uid_min /* Only respect users, not daemons etc. */) 720 712 { 721 VBoxServiceVerbose(4, "ConsoleKit: adding user \"%s\" to list\n", 722 ppwEntry->pw_name); 723 724 rc = RTStrDupEx(&papszUsers[cUsersInList], (const char *)ppwEntry->pw_name); 725 if (RT_FAILURE(rc)) 726 break; 727 cUsersInList++; 713 VBoxServiceVerbose(4, "ConsoleKit: session '%s' -> %s (uid: %RU32)\n", 714 *ppszCurSession, ppwEntry->pw_name, uid); 715 716 bool fFound = false; 717 for (uint32_t i = 0; i < cUsersInList && !fFound; i++) 718 fFound = strcmp(papszUsers[i], ppwEntry->pw_name) == 0; 719 720 if (!fFound) 721 { 722 VBoxServiceVerbose(4, "ConsoleKit: adding user \"%s\" to list\n", 723 ppwEntry->pw_name); 724 725 rc = RTStrDupEx(&papszUsers[cUsersInList], (const char *)ppwEntry->pw_name); 726 if (RT_FAILURE(rc)) 727 break; 728 cUsersInList++; 729 } 728 730 } 731 /* else silently ignore the user */ 729 732 } 730 733 else
Note:
See TracChangeset
for help on using the changeset viewer.