#include "lib/util/util_pw.h"
/**************************************************************************
- Wrappers for getpwuid(), getgrnam(), getgrgid()
+ Wrappers for getgrnam(), getgrgid()
****************************************************************************/
-struct passwd *sys_getpwuid(uid_t uid)
-{
- return getpwuid(uid);
-}
-
struct group *sys_getgrnam(const char *name)
{
return getgrnam(name);
{
struct passwd *temp;
- temp = sys_getpwuid(uid);
+ temp = getpwuid(uid);
if (!temp) {
#if 0
#ifndef __LIB_UTIL_UTIL_PW_H__
#define __LIB_UTIL_UTIL_PW_H__
-struct passwd *sys_getpwuid(uid_t uid);
struct group *sys_getgrnam(const char *name);
struct group *sys_getgrgid(gid_t gid);
struct passwd *tcopy_passwd(TALLOC_CTX *mem_ctx,
cache_data, struct security_token);
}
- if ( !(pw = sys_getpwuid(0)) ) {
+ if ( !(pw = getpwuid(0)) ) {
if ( !(pw = getpwnam("root")) ) {
- DEBUG(0,("get_root_nt_token: both sys_getpwuid(0) "
+ DEBUG(0,("get_root_nt_token: both getpwuid(0) "
"and getpwnam(\"root\") failed!\n"));
return NULL;
}
struct passwd *unix_pw;
bool ret;
- unix_pw = sys_getpwuid( uid );
+ unix_pw = getpwuid( uid );
if ( !unix_pw ) {
DEBUG(4,("pdb_default_uid_to_sid: host has no idea of uid "
st = smb_fname->st;
TALLOC_FREE(smb_fname);
- pwd = sys_getpwuid(st.st_ex_uid);
+ pwd = getpwuid(st.st_ex_uid);
if (pwd != NULL) user = pwd->pw_name;
else user = null_string;
grp = sys_getgrgid(st.st_ex_gid);
return NT_STATUS_UNSUCCESSFUL;
}
- pwd = sys_getpwuid(st.st_ex_uid);
+ pwd = getpwuid(st.st_ex_uid);
if (pwd != NULL) user = pwd->pw_name;
else user = null_string;
grp = sys_getgrgid(st.st_ex_gid);
st = smb_fname->st;
TALLOC_FREE(smb_fname);
- pwd = sys_getpwuid(st.st_ex_uid);
+ pwd = getpwuid(st.st_ex_uid);
if (pwd != NULL) user = pwd->pw_name;
else user = null_string;
grp = sys_getgrgid(st.st_ex_gid);