1
0
mirror of https://github.com/samba-team/samba.git synced 2025-07-30 19:42:05 +03:00

Fix broken net rpc join message when DC can't be found. Ensure we pass in a domain name.

Jeremy.
(This used to be commit 33019fe2b5)
This commit is contained in:
Jeremy Allison
2008-08-21 15:27:22 -07:00
parent efbb8c189d
commit 129e71a97a

View File

@ -476,7 +476,7 @@ bool net_find_pdc(struct sockaddr_storage *server_ss,
NTSTATUS net_make_ipc_connection(struct net_context *c, unsigned flags,
struct cli_state **pcli)
{
return net_make_ipc_connection_ex(c, NULL, NULL, NULL, flags, pcli);
return net_make_ipc_connection_ex(c, c->opt_workgroup, NULL, NULL, flags, pcli);
}
NTSTATUS net_make_ipc_connection_ex(struct net_context *c ,const char *domain,
@ -492,7 +492,8 @@ NTSTATUS net_make_ipc_connection_ex(struct net_context *c ,const char *domain,
if ( !server || !pss ) {
if (!net_find_server(c, domain, flags, &server_ss,
&server_name)) {
d_fprintf(stderr, "Unable to find a suitable server\n");
d_fprintf(stderr, "Unable to find a suitable server "
"for domain %s\n", domain);
nt_status = NT_STATUS_UNSUCCESSFUL;
goto done;
}