svn commit: samba r8500 - in branches/SAMBA_4_0/source/librpc/ndr: .

tridge at samba.org tridge at samba.org
Fri Jul 15 13:25:56 GMT 2005


Author: tridge
Date: 2005-07-15 13:25:56 +0000 (Fri, 15 Jul 2005)
New Revision: 8500

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

Log:
greatly reduce the number of build warnings on x86-64 (every NDR macro
in the generated code from pidl generated a warning)

Modified:
   branches/SAMBA_4_0/source/librpc/ndr/libndr.h


Changeset:
Modified: branches/SAMBA_4_0/source/librpc/ndr/libndr.h
===================================================================
--- branches/SAMBA_4_0/source/librpc/ndr/libndr.h	2005-07-15 13:19:16 UTC (rev 8499)
+++ branches/SAMBA_4_0/source/librpc/ndr/libndr.h	2005-07-15 13:25:56 UTC (rev 8500)
@@ -187,7 +187,7 @@
 
 #define NDR_PULL_NEED_BYTES(ndr, n) do { \
 	if ((n) > ndr->data_size || ndr->offset + (n) > ndr->data_size) { \
-		return ndr_pull_error(ndr, NDR_ERR_BUFSIZE, "Pull bytes %u", n); \
+		return ndr_pull_error(ndr, NDR_ERR_BUFSIZE, "Pull bytes %u", (unsigned)n); \
 	} \
 } while(0)
 
@@ -203,7 +203,7 @@
 		ndr->offset = (ndr->offset + (n-1)) & ~(n-1); \
 	} \
 	if (ndr->offset > ndr->data_size) { \
-		return ndr_pull_error(ndr, NDR_ERR_BUFSIZE, "Pull align %u", n); \
+		return ndr_pull_error(ndr, NDR_ERR_BUFSIZE, "Pull align %u", (unsigned)n); \
 	} \
 } while(0)
 
@@ -229,7 +229,7 @@
 	                       (s) = talloc_size(ndr, size); \
                                if ((size) && !(s)) return ndr_pull_error(ndr, NDR_ERR_ALLOC, \
 							       "Alloc %u failed\n", \
-							       size); \
+							       (unsigned)size); \
                            } while (0)
 
 #define NDR_ALLOC(ndr, s) NDR_ALLOC_SIZE(ndr, s, sizeof(*(s)))
@@ -237,7 +237,7 @@
 
 #define NDR_ALLOC_N_SIZE(ndr, s, n, elsize) do { \
 	(s) = talloc_array_size(ndr, elsize, n); \
-	if (!(s)) return ndr_pull_error(ndr, NDR_ERR_ALLOC, "Alloc %u * %u failed\n", n, elsize); \
+	if (!(s)) return ndr_pull_error(ndr, NDR_ERR_ALLOC, "Alloc %u * %u failed\n", (unsigned)n, (unsigned)elsize); \
 } while (0)
 
 #define NDR_ALLOC_N(ndr, s, n) NDR_ALLOC_N_SIZE(ndr, s, n, sizeof(*(s)))
@@ -245,7 +245,7 @@
 
 #define NDR_PUSH_ALLOC_SIZE(ndr, s, size) do { \
        (s) = talloc_size(ndr, size); \
-       if (!(s)) return ndr_push_error(ndr, NDR_ERR_ALLOC, "push alloc %u failed\n", size); \
+       if (!(s)) return ndr_push_error(ndr, NDR_ERR_ALLOC, "push alloc %u failed\n", (unsigned)size); \
 } while (0)
 
 #define NDR_PUSH_ALLOC(ndr, s) NDR_PUSH_ALLOC_SIZE(ndr, s, sizeof(*(s)))



More information about the samba-cvs mailing list