summaryrefslogtreecommitdiff
path: root/source3/nsswitch/wb_common.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2001-04-25 05:47:50 +0000
committerAndrew Tridgell <tridge@samba.org>2001-04-25 05:47:50 +0000
commit5f9dca64daea8bf910a66e1178ad0336628fdc9f (patch)
tree16e3da57db7ae142a68559ff1031bfcede85ac85 /source3/nsswitch/wb_common.c
parent77076b01d286ad296930cd83cafc3a4bf0ae5db6 (diff)
downloadsamba-5f9dca64daea8bf910a66e1178ad0336628fdc9f.tar.gz
samba-5f9dca64daea8bf910a66e1178ad0336628fdc9f.tar.bz2
samba-5f9dca64daea8bf910a66e1178ad0336628fdc9f.zip
merge some of the nsswitch code from tng to head
the libnss_winbind.so from head now works with the winbindd from tng (This used to be commit 67ccfd2826548a6ca22562f9fb3ae156a57bd7db)
Diffstat (limited to 'source3/nsswitch/wb_common.c')
-rw-r--r--source3/nsswitch/wb_common.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source3/nsswitch/wb_common.c b/source3/nsswitch/wb_common.c
index 98a4b6758b..4040e1cff2 100644
--- a/source3/nsswitch/wb_common.c
+++ b/source3/nsswitch/wb_common.c
@@ -37,7 +37,7 @@ void init_request(struct winbindd_request *request, int request_type)
static char *domain_env;
static BOOL initialised;
- request->cmd = (enum winbindd_cmd)request_type;
+ request->cmd = request_type;
request->pid = getpid();
request->domain[0] = '\0';
@@ -59,7 +59,7 @@ void init_response(struct winbindd_response *response)
{
/* Initialise return value */
- response->result = (enum winbindd_result)NSS_STATUS_UNAVAIL;
+ response->result = WINBINDD_ERROR;
}
/* Close established socket */
@@ -141,6 +141,7 @@ static int open_pipe_sock(void)
if (connect(established_socket, (struct sockaddr *)&sunaddr,
sizeof(sunaddr)) == -1) {
close_sock();
+ established_socket = -1;
return -1;
}
@@ -304,7 +305,7 @@ void free_response(struct winbindd_response *response)
/* Handle simple types of requests */
-enum nss_status winbindd_request(int req_type,
+NSS_STATUS winbindd_request(int req_type,
struct winbindd_request *request,
struct winbindd_response *response)
{