samba/samba-3.0.20-winbindd_v1.patch

62 lines
2.4 KiB
Diff
Raw Normal View History

diff -urBbN --exclude-from=diff.excludes samba-3.0.20-orig/source/nsswitch/winbindd_dual.c samba-3.0.20-new/source/nsswitch/winbindd_dual.c
--- samba-3.0.20-orig/source/nsswitch/winbindd_dual.c 2005-08-19 12:16:27.000000000 -0500
+++ samba-3.0.20-new/source/nsswitch/winbindd_dual.c 2005-08-29 13:34:16.000000000 -0500
@@ -158,7 +158,6 @@
return;
}
- if (state->response->result == WINBINDD_OK)
SMB_ASSERT(cache_retrieve_response(child->pid,
state->response));
@@ -486,12 +485,11 @@
DEBUG(4,("child daemon request %d\n",
(int)state.request.cmd));
+ ZERO_STRUCT(state.response);
state.request.null_term = '\0';
child_process_request(child->domain, &state);
- if (state.response.result == WINBINDD_OK)
- cache_store_response(sys_getpid(),
- &state.response);
+ cache_store_response(sys_getpid(), &state.response);
SAFE_FREE(state.response.extra_data);
diff -urBbN --exclude-from=diff.excludes samba-3.0.20-orig/source/nsswitch/winbindd_user.c samba-3.0.20-new/source/nsswitch/winbindd_user.c
--- samba-3.0.20-orig/source/nsswitch/winbindd_user.c 2005-07-28 08:19:44.000000000 -0500
+++ samba-3.0.20-new/source/nsswitch/winbindd_user.c 2005-08-29 16:04:22.000000000 -0500
@@ -230,6 +230,7 @@
const char *shell,
uint32 group_rid)
{
+ fstring username;
struct getpwsid_state *s =
talloc_get_type_abort(private_data, struct getpwsid_state);
@@ -240,7 +241,9 @@
return;
}
- s->username = talloc_strdup(s->state->mem_ctx, acct_name);
+ fstrcpy( username, acct_name );
+ strlower_m( username );
+ s->username = talloc_strdup(s->state->mem_ctx, username);
s->fullname = talloc_strdup(s->state->mem_ctx, full_name);
s->homedir = talloc_strdup(s->state->mem_ctx, homedir);
s->shell = talloc_strdup(s->state->mem_ctx, shell);
diff -urBbN --exclude-from=diff.excludes samba-3.0.20-orig/source/nsswitch/winbindd_util.c samba-3.0.20-new/source/nsswitch/winbindd_util.c
--- samba-3.0.20-orig/source/nsswitch/winbindd_util.c 2005-07-28 08:19:44.000000000 -0500
+++ samba-3.0.20-new/source/nsswitch/winbindd_util.c 2005-08-29 13:34:16.000000000 -0500
@@ -444,7 +444,9 @@
state->request.data.init_conn.dcname
[sizeof(state->request.data.init_conn.dcname)-1]='\0';
+ if (strlen(state->request.data.init_conn.dcname) > 0) {
fstrcpy(domain->dcname, state->request.data.init_conn.dcname);
+ }
if (strlen(domain->dcname) > 0) {
if (!resolve_name(domain->dcname, &ipaddr, 0x20)) {