* ldap.cc (user_attr): Remove "uid" attribute.

* ldap.h (LDAP_USER_NAME_ATTR): Remove.  Change other attribute index
	values as required.
	(cyg_ldap::get_user_name): Remove inline function.
	* uinfo.cc (pwdgrp::fetch_account_from_windows): Remove code to handle
	Cygwin username different from Windows username.
	(pwdgrp::add_account_from_cygserver): Remove unnecessary cast.
This commit is contained in:
Corinna Vinschen
2014-04-22 10:36:35 +00:00
parent 638f0ebf90
commit 93a1517f68
4 changed files with 21 additions and 20 deletions

View File

@@ -17,12 +17,11 @@ details. */
#include <ntldap.h>
#pragma pop_macro ("DECLSPEC_IMPORT")
#define LDAP_USER_NAME_ATTR 0
#define LDAP_USER_PGRP_ATTR 1
#define LDAP_USER_GECOS_ATTR 2
#define LDAP_USER_HOME_ATTR 3
#define LDAP_USER_SHELL_ATTR 4
#define LDAP_USER_UID_ATTR 5
#define LDAP_USER_PGRP_ATTR 0
#define LDAP_USER_GECOS_ATTR 1
#define LDAP_USER_HOME_ATTR 2
#define LDAP_USER_SHELL_ATTR 3
#define LDAP_USER_UID_ATTR 4
#define LDAP_GROUP_NAME_ATTR 0
#define LDAP_GROUP_GID_ATTR 1
@@ -58,7 +57,6 @@ public:
uint32_t fetch_posix_offset_for_domain (PCWSTR domain);
uid_t remap_uid (uid_t uid);
gid_t remap_gid (gid_t gid);
PWCHAR get_user_name () { return get_string_attribute (LDAP_USER_NAME_ATTR); }
/* User only */
gid_t get_primary_gid () { return get_num_attribute (LDAP_USER_PGRP_ATTR); }
PWCHAR get_gecos () { return get_string_attribute (LDAP_USER_GECOS_ATTR); }