svn commit: samba r16251 - branches/SAMBA_3_0/source/client branches/SAMBA_3_0/source/utils trunk/source/client trunk/source/utils

vlendec at samba.org vlendec at samba.org
Thu Jun 15 11:24:01 GMT 2006


Author: vlendec
Date: 2006-06-15 11:24:01 +0000 (Thu, 15 Jun 2006)
New Revision: 16251

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

Log:
for i in `seq 1 1000`
do
	echo "I will always compile before commit :-)"
done

Also fix Klokwork ID 806.

Volker


Modified:
   branches/SAMBA_3_0/source/client/client.c
   branches/SAMBA_3_0/source/utils/net_usershare.c
   trunk/source/client/client.c
   trunk/source/utils/net_usershare.c


Changeset:
Modified: branches/SAMBA_3_0/source/client/client.c
===================================================================
--- branches/SAMBA_3_0/source/client/client.c	2006-06-15 11:17:57 UTC (rev 16250)
+++ branches/SAMBA_3_0/source/client/client.c	2006-06-15 11:24:01 UTC (rev 16251)
@@ -1008,7 +1008,7 @@
 
 	while (next_token_nr(NULL,p,NULL,sizeof(buf))) {
 		pstrcpy(mget_mask,cur_dir);
-		if ((mask[0] != '\0') && (mget_mask[strlen(mget_mask)-1]!='\\'))
+		if ((mget_mask[0] != '\0') && (mget_mask[strlen(mget_mask)-1]!='\\'))
 			pstrcat(mget_mask,"\\");
 		
 		if (*p == '\\')

Modified: branches/SAMBA_3_0/source/utils/net_usershare.c
===================================================================
--- branches/SAMBA_3_0/source/utils/net_usershare.c	2006-06-15 11:17:57 UTC (rev 16250)
+++ branches/SAMBA_3_0/source/utils/net_usershare.c	2006-06-15 11:24:01 UTC (rev 16251)
@@ -129,7 +129,7 @@
 static void get_basepath(pstring basepath)
 {
 	pstrcpy(basepath, lp_usershare_path());
-	if (basepath[strlen(basepath)-1] == '/') {
+	if ((basepath[0] != '\0') && (basepath[strlen(basepath)-1] == '/')) {
 		basepath[strlen(basepath)-1] = '\0';
 	}
 }

Modified: trunk/source/client/client.c
===================================================================
--- trunk/source/client/client.c	2006-06-15 11:17:57 UTC (rev 16250)
+++ trunk/source/client/client.c	2006-06-15 11:24:01 UTC (rev 16251)
@@ -1008,7 +1008,7 @@
 
 	while (next_token_nr(NULL,p,NULL,sizeof(buf))) {
 		pstrcpy(mget_mask,cur_dir);
-		if ((mask[0] != '\0') && (mget_mask[strlen(mget_mask)-1]!='\\'))
+		if ((mget_mask[0] != '\0') && (mget_mask[strlen(mget_mask)-1]!='\\'))
 			pstrcat(mget_mask,"\\");
 		
 		if (*p == '\\')

Modified: trunk/source/utils/net_usershare.c
===================================================================
--- trunk/source/utils/net_usershare.c	2006-06-15 11:17:57 UTC (rev 16250)
+++ trunk/source/utils/net_usershare.c	2006-06-15 11:24:01 UTC (rev 16251)
@@ -129,7 +129,7 @@
 static void get_basepath(pstring basepath)
 {
 	pstrcpy(basepath, lp_usershare_path());
-	if (basepath[strlen(basepath)-1] == '/') {
+	if ((basepath[0] != '\0') && (basepath[strlen(basepath)-1] == '/')) {
 		basepath[strlen(basepath)-1] = '\0';
 	}
 }



More information about the samba-cvs mailing list