svn commit: samba r6070 - in branches/SAMBA_4_0/source/lib: . socket

jelmer at samba.org jelmer at samba.org
Sat Mar 26 01:08:59 GMT 2005


Author: jelmer
Date: 2005-03-26 01:08:59 +0000 (Sat, 26 Mar 2005)
New Revision: 6070

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=6070

Log:
Fix typo's and fallback to "" as default user name if no 
other username could be guessed.

Modified:
   branches/SAMBA_4_0/source/lib/credentials.c
   branches/SAMBA_4_0/source/lib/socket/socket_unix.c


Changeset:
Modified: branches/SAMBA_4_0/source/lib/credentials.c
===================================================================
--- branches/SAMBA_4_0/source/lib/credentials.c	2005-03-26 00:44:46 UTC (rev 6069)
+++ branches/SAMBA_4_0/source/lib/credentials.c	2005-03-26 01:08:59 UTC (rev 6070)
@@ -29,7 +29,7 @@
 /* Create a new credentials structure, on the specified TALLOC_CTX */
 struct cli_credentials *cli_credentials_init(TALLOC_CTX *mem_ctx) 
 {
-	struct cli_credentails *cred = talloc_zero(mem_ctx, struct cli_credentials);
+	struct cli_credentials *cred = talloc_zero(mem_ctx, struct cli_credentials);
 	if (!cred) {
 		return cred;
 	}
@@ -311,6 +311,7 @@
 {
 	char *p;
 
+	cli_credentials_set_username(cred, "", CRED_GUESSED);
 	cli_credentials_set_conf(cred);
 	
 	if (getenv("LOGNAME")) {
@@ -455,7 +456,7 @@
 	const char *username = cli_credentials_get_username(cred);
 
 	/* Yes, it is deliberate that we die if we have a NULL pointer
-	 * here - anymous is "", not NULL, which is 'never specified,
+	 * here - anonymous is "", not NULL, which is 'never specified,
 	 * never guessed', ie programmer bug */
 	if (!username[0]) 
 		return True;

Modified: branches/SAMBA_4_0/source/lib/socket/socket_unix.c
===================================================================
--- branches/SAMBA_4_0/source/lib/socket/socket_unix.c	2005-03-26 00:44:46 UTC (rev 6069)
+++ branches/SAMBA_4_0/source/lib/socket/socket_unix.c	2005-03-26 01:08:59 UTC (rev 6070)
@@ -23,7 +23,6 @@
 
 #include "includes.h"
 #include "lib/socket/socket.h"
-#include "lib/socket/socket.h"
 #include "system/network.h"
 #include "system/filesys.h"
 



More information about the samba-cvs mailing list