Bug 1022 - Loop during winbind nss processing
Summary: Loop during winbind nss processing
Status: CLOSED FIXED
Alias: None
Product: Samba 3.0
Classification: Unclassified
Component: winbind (show other bugs)
Version: 3.0.1
Hardware: All Linux
: P3 normal
Target Milestone: none
Assignee: Gerald (Jerry) Carter (dead mail address)
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-01-31 22:55 UTC by L. Lucius
Modified: 2005-11-14 09:30 UTC (History)
0 users

See Also:


Attachments
Updates winbind_nss_linux.c to fix problem (837 bytes, patch)
2004-01-31 22:56 UTC, L. Lucius
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description L. Lucius 2004-01-31 22:55:16 UTC
The loop occurs when any of the winbind nss functions calls the get_static() 
function in winbind_nss_linux.c due to a 64-bit problem.  This patch fixes it 
and a couple of minor fprintf() debugs.

--- winbind_nss_linux.c.orig	2004-01-16 07:11:01.000000000 -0600
+++ winbind_nss_linux.c	2004-01-31 22:12:35.000000000 -0600
@@ -38,7 +38,7 @@
    are the pointers passed in by the C library to the _nss_ntdom_*
    functions. */
 
-static char *get_static(char **buffer, int *buflen, int len)
+static char *get_static(char **buffer, size_t *buflen, int len)
 {
 	char *result;
 
@@ -1080,7 +1080,7 @@
 	struct winbindd_request request;
 
 #ifdef DEBUG_NSS
-	fprintf(stderr, "[%5d]: uidtosid %s\n", getpid(), name);
+	fprintf(stderr, "[%5d]: uidtosid %d\n", getpid(), uid);
 #endif
 
 	ZERO_STRUCT(response);
@@ -1119,7 +1119,7 @@
 	struct winbindd_request request;
 
 #ifdef DEBUG_NSS
-	fprintf(stderr, "[%5d]: gidtosid %s\n", getpid(), name);
+	fprintf(stderr, "[%5d]: gidtosid %d\n", getpid(), gid);
 #endif
 
 	ZERO_STRUCT(response);
Comment 1 L. Lucius 2004-01-31 22:56:50 UTC
Created attachment 376 [details]
Updates winbind_nss_linux.c to fix problem
Comment 2 Gerald (Jerry) Carter (dead mail address) 2004-03-12 06:51:26 UTC
Looks like someone has already applied the 
patch to the 3.0 tree.  Marking as fixed.  
Thanks for the patch.
Comment 3 Gerald (Jerry) Carter (dead mail address) 2005-08-24 10:19:21 UTC
sorry for the same, cleaning up the database to prevent unecessary reopens of bugs.
Comment 4 Gerald (Jerry) Carter (dead mail address) 2005-11-14 09:30:33 UTC
database cleanup