[SCM] Samba Shared Repository - branch master updated

Jeremy Allison jra at samba.org
Mon Aug 16 17:21:01 UTC 2021


The branch, master has been updated
       via  1ce08f72a9e testsuite: Fix build with gcc >= 11.1.1
       via  86fddfa3116 lib:replace: Remove trailing spaces from testsuite.c
      from  0f26dbe0d09 gpo: Print getcert message to debug

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


- Log -----------------------------------------------------------------
commit 1ce08f72a9e2558e8720b463e68174e430a67654
Author: Andreas Schneider <asn at samba.org>
Date:   Mon Aug 16 12:42:47 2021 +0200

    testsuite: Fix build with gcc >= 11.1.1
    
    Pair-Programmed-With: Jeremy Allison <jra at samba.org>
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Signed-off-by: Jeremy Allison <jra at samba.org>
    
    Autobuild-User(master): Jeremy Allison <jra at samba.org>
    Autobuild-Date(master): Mon Aug 16 17:20:37 UTC 2021 on sn-devel-184

commit 86fddfa3116a8dec86e02088a3abc3859f38a251
Author: Andreas Schneider <asn at samba.org>
Date:   Mon Aug 16 12:39:31 2021 +0200

    lib:replace: Remove trailing spaces from testsuite.c
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

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

Summary of changes:
 lib/replace/tests/testsuite.c | 16 ++++++++++------
 1 file changed, 10 insertions(+), 6 deletions(-)


Changeset truncated at 500 lines:

diff --git a/lib/replace/tests/testsuite.c b/lib/replace/tests/testsuite.c
index b4b038af8c7..c0dcda55bd2 100644
--- a/lib/replace/tests/testsuite.c
+++ b/lib/replace/tests/testsuite.c
@@ -1,4 +1,4 @@
-/* 
+/*
    Unix SMB/CIFS implementation.
 
    libreplace tests
@@ -8,7 +8,7 @@
      ** NOTE! The following LGPL license applies to the talloc
      ** library. This does NOT imply that all of Samba is released
      ** under the LGPL
-   
+
    This library is free software; you can redistribute it and/or
    modify it under the terms of the GNU Lesser General Public
    License as published by the Free Software Foundation; either
@@ -127,7 +127,7 @@ static int test_strlcat(void)
 		return false;
 	}
 	if (strcmp(tmp, "bl") != 0) {
-		printf("failure: strlcat [\nexpected \"bl\", got \"%s\"\n]\n", 
+		printf("failure: strlcat [\nexpected \"bl\", got \"%s\"\n]\n",
 			   tmp);
 		return false;
 	}
@@ -179,7 +179,7 @@ static int test_strdup(void)
 	free(x);
 	printf("success: strdup\n");
 	return true;
-}	
+}
 
 static int test_setlinebuf(void)
 {
@@ -308,6 +308,8 @@ static int test_strndup(void)
 
 static int test_strnlen(void)
 {
+	char longlen[20] = { 0 };
+
 	printf("test: strnlen\n");
 	if (strnlen("bla", 2) != 2) {
 		printf("failure: strnlen [\nunexpected length\n]\n");
@@ -319,7 +321,9 @@ static int test_strnlen(void)
 		return false;
 	}
 
-	if (strnlen("some text", 20) != 9) {
+	memcpy(longlen, "some text", 10);
+
+	if (strnlen(longlen, 20) != 9) {
 		printf("failure: strnlen [\nunexpected length\n]\n");
 		return false;
 	}
@@ -774,7 +778,7 @@ static int test_strtoull(void)
 	return true;
 }
 
-/* 
+/*
 FIXME:
 Types:
 bool


-- 
Samba Shared Repository



More information about the samba-cvs mailing list