[SCM] Samba Shared Repository - branch master updated

Günther Deschner gd at samba.org
Fri Dec 17 04:21:02 MST 2010


The branch, master has been updated
       via  4f4ac64 s4-smbtorture: skip level 8 checks in test_GetDriverInfo_winreg for w2k3.
       via  5083be5 s4-smbtorture: skipping level 8 driveradds against w2k3.
       via  28d618d s4-smbtorture: add torture_assert_strn_equal macro.
       via  f08fdfa s3-net: fix net sid type build warning.
      from  7f572df s3/net: tz argument should be NULL of course

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 4f4ac6462a191418ff358d28ac298352861107d4
Author: Günther Deschner <gd at samba.org>
Date:   Thu Dec 16 16:01:51 2010 +0100

    s4-smbtorture: skip level 8 checks in test_GetDriverInfo_winreg for w2k3.
    
    Guenther
    
    Autobuild-User: Günther Deschner <gd at samba.org>
    Autobuild-Date: Fri Dec 17 12:20:38 CET 2010 on sn-devel-104

commit 5083be506eaa58c59d867f04a941c0e5707ca44c
Author: Günther Deschner <gd at samba.org>
Date:   Thu Dec 16 11:58:36 2010 +0100

    s4-smbtorture: skipping level 8 driveradds against w2k3.
    
    Guenther

commit 28d618ddf015f502ef0fa8a5f8472123c7cd9102
Author: Günther Deschner <gd at samba.org>
Date:   Wed Dec 15 17:44:23 2010 +0100

    s4-smbtorture: add torture_assert_strn_equal macro.
    
    Guenther

commit f08fdfae27ee0da5750c3f843ad829e1fa8f57b1
Author: Günther Deschner <gd at samba.org>
Date:   Thu Dec 16 12:40:47 2010 +0100

    s3-net: fix net sid type build warning.
    
    Guenther

-----------------------------------------------------------------------

Summary of changes:
 lib/torture/torture.h         |   10 ++++++++++
 source3/utils/net_rpc.c       |    2 +-
 source4/torture/rpc/spoolss.c |   23 ++++++++++++++++++++++-
 3 files changed, 33 insertions(+), 2 deletions(-)


Changeset truncated at 500 lines:

diff --git a/lib/torture/torture.h b/lib/torture/torture.h
index aeedd71..39f83df 100644
--- a/lib/torture/torture.h
+++ b/lib/torture/torture.h
@@ -311,6 +311,16 @@ void torture_result(struct torture_context *test,
 	} \
 	} while(0)
 
+#define torture_assert_strn_equal(torture_ctx,got,expected,len,cmt)\
+	do { const char *__got = (got), *__expected = (expected); \
+	if (strncmp(__got, __expected, len) != 0) { \
+		torture_result(torture_ctx, TORTURE_FAIL, \
+					   __location__": "#got" %s of len %d did not match "#expected" %s: %s", \
+					   __got, (int)len, __expected, cmt); \
+		return false; \
+	} \
+	} while(0)
+
 #define torture_assert_str_equal_goto(torture_ctx,got,expected,ret,label,cmt)\
 	do { const char *__got = (got), *__expected = (expected); \
 	if (strcmp_safe(__got, __expected) != 0) { \
diff --git a/source3/utils/net_rpc.c b/source3/utils/net_rpc.c
index 228f7eb..27d839a 100644
--- a/source3/utils/net_rpc.c
+++ b/source3/utils/net_rpc.c
@@ -4240,7 +4240,7 @@ static bool get_user_sids(const char *domain, const char *user, struct security_
 		return false;
 	}
 
-	if (type != SID_NAME_USER) {
+	if (type != WBC_SID_NAME_USER) {
 		wbcFreeMemory(sid_str);
 		DEBUG(1, ("%s is not a user\n", full_name));
 		return false;
diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c
index 925b703..bc40aea 100644
--- a/source4/torture/rpc/spoolss.c
+++ b/source4/torture/rpc/spoolss.c
@@ -4628,6 +4628,10 @@ static bool test_GetDriverInfo_winreg(struct torture_context *tctx,
 		goto try_level3;
 	}
 
+	if (torture_setting_bool(tctx, "w2k3", false)) {
+		goto try_level6;
+	}
+
 	torture_assert(tctx,
 		test_GetPrinterDriver2_level(tctx, b, handle, driver_name, environment, 8, 3, 0, &info, &result),
 		"failed to get driver info level 8");
@@ -8858,6 +8862,15 @@ static bool test_add_driver_arg(struct torture_context *tctx,
 				break;
 			}
 		}
+		if (torture_setting_bool(tctx, "w2k3", false)) {
+			switch (levels[i]) {
+			case 8:
+				torture_comment(tctx, "skipping level %d against w2k3\n", levels[i]);
+				continue;
+			default:
+				break;
+			}
+		}
 
 		torture_comment(tctx,
 			"Testing PrinterDriver%s '%s' add & delete level %d\n",
@@ -8885,7 +8898,15 @@ static bool test_add_driver_arg(struct torture_context *tctx,
 				break;
 			}
 		}
-
+		if (torture_setting_bool(tctx, "w2k3", false)) {
+			switch (levels[i]) {
+			case 8:
+				torture_comment(tctx, "skipping level %d against w2k3\n", levels[i]);
+				continue;
+			default:
+				break;
+			}
+		}
 
 		torture_comment(tctx,
 			"Testing PrinterDriver%s '%s' add & delete level %d (full unc paths)\n",


-- 
Samba Shared Repository


More information about the samba-cvs mailing list