svn commit: samba r5897 - in branches/SAMBA_3_0/source/client: .
sfrench at samba.org
sfrench at samba.org
Sat Mar 19 05:45:54 GMT 2005
Author: sfrench
Date: 2005-03-19 05:45:53 +0000 (Sat, 19 Mar 2005)
New Revision: 5897
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=5897
Log:
Fix domain name parsing for cifs mount util
Modified:
branches/SAMBA_3_0/source/client/mount.cifs.c
Changeset:
Modified: branches/SAMBA_3_0/source/client/mount.cifs.c
===================================================================
--- branches/SAMBA_3_0/source/client/mount.cifs.c 2005-03-19 05:00:57 UTC (rev 5896)
+++ branches/SAMBA_3_0/source/client/mount.cifs.c 2005-03-19 05:45:53 UTC (rev 5897)
@@ -61,7 +61,7 @@
static int free_share_name = 0;
static char * user_name = NULL;
static char * mountpassword = NULL;
-static char * domain_name = NULL;
+char * domain_name = NULL;
/* BB finish BB
@@ -632,7 +632,6 @@
/* move_string(*ppuser, usernm+1) */
len = strlen(usernm+1);
- printf("\nlen %d original_len %d\n",len, original_len);
if(len >= original_len) {
/* should not happen */
@@ -776,7 +775,6 @@
int flags = MS_MANDLOCK; /* no need to set legacy MS_MGC_VAL */
char * orgoptions = NULL;
char * share_name = NULL;
- char * domain_name = NULL;
char * ipaddr = NULL;
char * uuid = NULL;
char * mountpoint;
@@ -927,14 +925,12 @@
if (orgoptions && parse_options(orgoptions, &flags))
return -1;
-
ipaddr = parse_server(&share_name);
if((ipaddr == NULL) && (got_ip == 0)) {
printf("No ip address specified and hostname not found\n");
return -1;
}
-
/* BB save off path and pop after mount returns? */
resolved_path = malloc(PATH_MAX+1);
if(resolved_path) {
@@ -1022,13 +1018,14 @@
domain_name = check_for_domain(&user_name);
strncat(options,",user=",6);
strcat(options,user_name);
- }
- if(retry == 0)
+ }
+ if(retry == 0) {
if(domain_name) {
/* extra length accounted for in option string above */
strncat(options,",domain=",8);
strcat(options,domain_name);
}
+ }
if(mountpassword) {
/* Commas have to be doubled, or else they will
look like the parameter separator */
More information about the samba-cvs
mailing list