svn commit: samba r18027 - in branches: SAMBA_3_0/source/lib
SAMBA_4_0/source/lib/talloc
vlendec at samba.org
vlendec at samba.org
Mon Sep 4 08:55:59 GMT 2006
Author: vlendec
Date: 2006-09-04 08:55:58 +0000 (Mon, 04 Sep 2006)
New Revision: 18027
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18027
Log:
Fix some 64-bit warnings
Modified:
branches/SAMBA_3_0/source/lib/talloc.c
branches/SAMBA_3_0/source/lib/talloctort.c
branches/SAMBA_4_0/source/lib/talloc/talloc.c
branches/SAMBA_4_0/source/lib/talloc/testsuite.c
Changeset:
Modified: branches/SAMBA_3_0/source/lib/talloc.c
===================================================================
--- branches/SAMBA_3_0/source/lib/talloc.c 2006-09-04 04:54:20 UTC (rev 18026)
+++ branches/SAMBA_3_0/source/lib/talloc.c 2006-09-04 08:55:58 UTC (rev 18027)
@@ -890,7 +890,7 @@
name,
(unsigned long)talloc_total_size(ptr),
(unsigned long)talloc_total_blocks(ptr),
- talloc_reference_count(ptr));
+ (int)talloc_reference_count(ptr));
}
/*
Modified: branches/SAMBA_3_0/source/lib/talloctort.c
===================================================================
--- branches/SAMBA_3_0/source/lib/talloctort.c 2006-09-04 04:54:20 UTC (rev 18026)
+++ branches/SAMBA_3_0/source/lib/talloctort.c 2006-09-04 08:55:58 UTC (rev 18027)
@@ -960,8 +960,10 @@
s1 = talloc_ptrtype(top, s1);location1 = __location__;
if (talloc_get_size(s1) != sizeof(struct struct1)) {
- printf("%s: talloc_ptrtype() allocated the wrong size %u (should be %u)\n",
- __location__, talloc_get_size(s1), sizeof(struct struct1));
+ printf("%s: talloc_ptrtype() allocated the wrong size %lu "
+ "(should be %lu)\n",
+ __location__, (unsigned long)talloc_get_size(s1),
+ (unsigned long)sizeof(struct struct1));
ret = False;
}
@@ -974,22 +976,27 @@
s2 = talloc_array_ptrtype(top, s2, 10);location2 = __location__;
if (talloc_get_size(s2) != (sizeof(struct struct1) * 10)) {
- printf("%s: talloc_array_ptrtype() allocated the wrong size %u (should be %u)\n",
- __location__, talloc_get_size(s2), (sizeof(struct struct1)*10));
+ printf("%s: talloc_array_ptrtype() allocated the wrong size "
+ "%lu (should be %lu)\n",
+ __location__, (unsigned long)talloc_get_size(s2),
+ (unsigned long)(sizeof(struct struct1)*10));
ret = False;
}
if (strcmp(location2, talloc_get_name(s2)) != 0) {
printf("%s: talloc_array_ptrtype() sets the wrong name '%s' (should be '%s')\n",
- __location__, talloc_get_name(s2), location2);
+ __location__, talloc_get_name(s2),
+ location2);
ret = False;
}
s3 = talloc_array_ptrtype(top, s3, 10);location3 = __location__;
if (talloc_get_size(s3) != (sizeof(struct struct1 *) * 10)) {
- printf("%s: talloc_array_ptrtype() allocated the wrong size %u (should be %u)\n",
- __location__, talloc_get_size(s3), (sizeof(struct struct1 *)*10));
+ printf("%s: talloc_array_ptrtype() allocated the wrong size "
+ "%lu (should be %lu)\n",
+ __location__, (unsigned long)talloc_get_size(s3),
+ (unsigned long)(sizeof(struct struct1 *)*10));
ret = False;
}
@@ -1002,8 +1009,10 @@
s4 = talloc_array_ptrtype(top, s4, 10);location4 = __location__;
if (talloc_get_size(s4) != (sizeof(struct struct1 **) * 10)) {
- printf("%s: talloc_array_ptrtype() allocated the wrong size %u (should be %u)\n",
- __location__, talloc_get_size(s4), (sizeof(struct struct1 **)*10));
+ printf("%s: talloc_array_ptrtype() allocated the wrong size "
+ "%lu (should be %lu)\n",
+ __location__, (unsigned long)talloc_get_size(s4),
+ (unsigned long)(sizeof(struct struct1 **)*10));
ret = False;
}
Modified: branches/SAMBA_4_0/source/lib/talloc/talloc.c
===================================================================
--- branches/SAMBA_4_0/source/lib/talloc/talloc.c 2006-09-04 04:54:20 UTC (rev 18026)
+++ branches/SAMBA_4_0/source/lib/talloc/talloc.c 2006-09-04 08:55:58 UTC (rev 18027)
@@ -890,7 +890,7 @@
name,
(unsigned long)talloc_total_size(ptr),
(unsigned long)talloc_total_blocks(ptr),
- talloc_reference_count(ptr));
+ (int)talloc_reference_count(ptr));
}
/*
Modified: branches/SAMBA_4_0/source/lib/talloc/testsuite.c
===================================================================
--- branches/SAMBA_4_0/source/lib/talloc/testsuite.c 2006-09-04 04:54:20 UTC (rev 18026)
+++ branches/SAMBA_4_0/source/lib/talloc/testsuite.c 2006-09-04 08:55:58 UTC (rev 18027)
@@ -960,8 +960,10 @@
s1 = talloc_ptrtype(top, s1);location1 = __location__;
if (talloc_get_size(s1) != sizeof(struct struct1)) {
- printf("%s: talloc_ptrtype() allocated the wrong size %u (should be %u)\n",
- __location__, talloc_get_size(s1), sizeof(struct struct1));
+ printf("%s: talloc_ptrtype() allocated the wrong size %lu "
+ "(should be %lu)\n",
+ __location__, (unsigned long)talloc_get_size(s1),
+ (unsigned long)sizeof(struct struct1));
ret = False;
}
@@ -974,22 +976,27 @@
s2 = talloc_array_ptrtype(top, s2, 10);location2 = __location__;
if (talloc_get_size(s2) != (sizeof(struct struct1) * 10)) {
- printf("%s: talloc_array_ptrtype() allocated the wrong size %u (should be %u)\n",
- __location__, talloc_get_size(s2), (sizeof(struct struct1)*10));
+ printf("%s: talloc_array_ptrtype() allocated the wrong size "
+ "%lu (should be %lu)\n",
+ __location__, (unsigned long)talloc_get_size(s2),
+ (unsigned long)(sizeof(struct struct1)*10));
ret = False;
}
if (strcmp(location2, talloc_get_name(s2)) != 0) {
printf("%s: talloc_array_ptrtype() sets the wrong name '%s' (should be '%s')\n",
- __location__, talloc_get_name(s2), location2);
+ __location__, talloc_get_name(s2),
+ location2);
ret = False;
}
s3 = talloc_array_ptrtype(top, s3, 10);location3 = __location__;
if (talloc_get_size(s3) != (sizeof(struct struct1 *) * 10)) {
- printf("%s: talloc_array_ptrtype() allocated the wrong size %u (should be %u)\n",
- __location__, talloc_get_size(s3), (sizeof(struct struct1 *)*10));
+ printf("%s: talloc_array_ptrtype() allocated the wrong size "
+ "%lu (should be %lu)\n",
+ __location__, (unsigned long)talloc_get_size(s3),
+ (unsigned long)(sizeof(struct struct1 *)*10));
ret = False;
}
@@ -1002,8 +1009,10 @@
s4 = talloc_array_ptrtype(top, s4, 10);location4 = __location__;
if (talloc_get_size(s4) != (sizeof(struct struct1 **) * 10)) {
- printf("%s: talloc_array_ptrtype() allocated the wrong size %u (should be %u)\n",
- __location__, talloc_get_size(s4), (sizeof(struct struct1 **)*10));
+ printf("%s: talloc_array_ptrtype() allocated the wrong size "
+ "%lu (should be %lu)\n",
+ __location__, (unsigned long)talloc_get_size(s4),
+ (unsigned long)(sizeof(struct struct1 **)*10));
ret = False;
}
More information about the samba-cvs
mailing list