diff options
author | Tim Potter <tpot@samba.org> | 2005-11-30 02:08:15 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:46:52 -0500 |
commit | 03d301ead5f702872b8cb948b8cd01b0fa0db5f7 (patch) | |
tree | bfecef5d67424c708c0122b591458328f6138ce1 /source4/torture | |
parent | ad02b0bee4c8554499e02e93903e64d599c11475 (diff) | |
download | samba-03d301ead5f702872b8cb948b8cd01b0fa0db5f7.tar.gz samba-03d301ead5f702872b8cb948b8cd01b0fa0db5f7.tar.bz2 samba-03d301ead5f702872b8cb948b8cd01b0fa0db5f7.zip |
r11967: Fix more 64-bit warnings.
(This used to be commit 9c4436a124f874ae240feaf590141d48c33a635f)
Diffstat (limited to 'source4/torture')
-rw-r--r-- | source4/torture/basic/denytest.c | 4 | ||||
-rw-r--r-- | source4/torture/nbt/winsreplication.c | 8 | ||||
-rw-r--r-- | source4/torture/rpc/dssync.c | 16 | ||||
-rw-r--r-- | source4/torture/rpc/samsync.c | 8 | ||||
-rw-r--r-- | source4/torture/smb2/connect.c | 12 | ||||
-rw-r--r-- | source4/torture/smb2/scan.c | 12 | ||||
-rw-r--r-- | source4/torture/smb2/util.c | 10 | ||||
-rw-r--r-- | source4/torture/torture_util.c | 4 |
8 files changed, 38 insertions, 36 deletions
diff --git a/source4/torture/basic/denytest.c b/source4/torture/basic/denytest.c index 3d2c57f998..9f559b7c76 100644 --- a/source4/torture/basic/denytest.c +++ b/source4/torture/basic/denytest.c @@ -1471,7 +1471,7 @@ BOOL torture_denytest1(void) tdif = usec_time_diff(&tv, &tv_start); tdif /= 1000; printf("%lld: %s %8s %10s %8s %10s %s (correct=%s)\n", - tdif, + (long long)tdif, fname, denystr(denytable1[i].deny1), openstr(denytable1[i].mode1), @@ -1568,7 +1568,7 @@ BOOL torture_denytest2(void) tdif = usec_time_diff(&tv, &tv_start); tdif /= 1000; printf("%lld: %s %8s %10s %8s %10s %s (correct=%s)\n", - tdif, + (long long)tdif, fname, denystr(denytable2[i].deny1), openstr(denytable2[i].mode1), diff --git a/source4/torture/nbt/winsreplication.c b/source4/torture/nbt/winsreplication.c index 87b2c26211..4f18e3492b 100644 --- a/source4/torture/nbt/winsreplication.c +++ b/source4/torture/nbt/winsreplication.c @@ -47,7 +47,7 @@ #define CHECK_VALUE_UINT64(v, correct) do { \ if ((v) != (correct)) { \ printf("(%s) Incorrect value %s=%llu - should be %llu\n", \ - __location__, #v, v, correct); \ + __location__, #v, (long long)v, (long long)correct); \ ret = False; \ goto done; \ }} while (0) @@ -230,7 +230,7 @@ static void display_entry(TALLOC_CTX *mem_ctx, struct wrepl_name *name) printf("%s\n", nbt_name_string(mem_ctx, &name->name)); printf("\tTYPE:%u STATE:%u NODE:%u STATIC:%u VERSION_ID: %llu\n", - name->type, name->state, name->node, name->is_static, name->version_id); + name->type, name->state, name->node, name->is_static, (long long)name->version_id); printf("\tRAW_FLAGS: 0x%08X OWNER: %-15s\n", name->raw_flags, name->owner); for (i=0;i<name->num_addresses;i++) { @@ -296,8 +296,8 @@ static BOOL test_wins_replication(TALLOC_CTX *mem_ctx, const char *address) struct wrepl_wins_owner *partner = &pull_table.out.partners[i]; printf("%s max_version=%6llu min_version=%6llu type=%d\n", partner->address, - partner->max_version, - partner->min_version, + (long long)partner->max_version, + (long long)partner->min_version, partner->type); pull_names.in.assoc_ctx = associate.out.assoc_ctx; diff --git a/source4/torture/rpc/dssync.c b/source4/torture/rpc/dssync.c index 9e9348283a..84d6c39b63 100644 --- a/source4/torture/rpc/dssync.c +++ b/source4/torture/rpc/dssync.c @@ -476,14 +476,14 @@ static BOOL test_FetchData(struct DsSyncTest *ctx) if (r.in.level == 5) { DEBUG(0,("start[%d] tmp_higest_usn: %llu , highest_usn: %llu\n",y, - r.in.req.req5.highwatermark.tmp_highest_usn, - r.in.req.req5.highwatermark.highest_usn)); + (long long)r.in.req.req5.highwatermark.tmp_highest_usn, + (long long)r.in.req.req5.highwatermark.highest_usn)); } if (r.in.level == 8) { DEBUG(0,("start[%d] tmp_higest_usn: %llu , highest_usn: %llu\n",y, - r.in.req.req8.highwatermark.tmp_highest_usn, - r.in.req.req8.highwatermark.highest_usn)); + (long long)r.in.req.req8.highwatermark.tmp_highest_usn, + (long long)r.in.req.req8.highwatermark.highest_usn)); } status = dcerpc_drsuapi_DsGetNCChanges(ctx->new_dc.drsuapi.pipe, ctx, &r); @@ -509,8 +509,8 @@ static BOOL test_FetchData(struct DsSyncTest *ctx) if (out_level == 1) { DEBUG(0,("end[%d] tmp_highest_usn: %llu , highest_usn: %llu\n",y, - ctr1->new_highwatermark.tmp_highest_usn, - ctr1->new_highwatermark.highest_usn)); + (long long)ctr1->new_highwatermark.tmp_highest_usn, + (long long)ctr1->new_highwatermark.highest_usn)); test_analyse_objects(ctx, ctr1->first_object); @@ -532,8 +532,8 @@ static BOOL test_FetchData(struct DsSyncTest *ctx) if (out_level == 6) { DEBUG(0,("end[%d] tmp_highest_usn: %llu , highest_usn: %llu\n",y, - ctr6->new_highwatermark.tmp_highest_usn, - ctr6->new_highwatermark.highest_usn)); + (long long)ctr6->new_highwatermark.tmp_highest_usn, + (long long)ctr6->new_highwatermark.highest_usn)); test_analyse_objects(ctx, ctr6->first_object); diff --git a/source4/torture/rpc/samsync.c b/source4/torture/rpc/samsync.c index 79dd8c9833..ad29d96b71 100644 --- a/source4/torture/rpc/samsync.c +++ b/source4/torture/rpc/samsync.c @@ -211,7 +211,9 @@ static struct sec_desc_buf *samsync_query_lsa_sec_desc(TALLOC_CTX *mem_ctx, #define TEST_UINT64_EQUAL(i1, i2) do {\ if (i1 != i2) {\ printf("%s: uint64 mismatch: " #i1 ": 0x%016llx (%lld) != " #i2 ": 0x%016llx (%lld)\n", \ - __location__, i1, i1, i2, i2);\ + __location__, \ + (long long)i1, (long long)i1, \ + (long long)i2, (long long)i2);\ ret = False;\ } \ } while (0) @@ -318,7 +320,7 @@ static BOOL samsync_handle_domain(TALLOC_CTX *mem_ctx, struct samsync_state *sam printf("\tsequence_nums[%d/%s]=%llu\n", database_id, domain->domain_name.string, - samsync_state->seq_num[database_id]); + (long long)samsync_state->seq_num[database_id]); for (i=0;i<ARRAY_SIZE(levels);i++) { q[levels[i]].in.domain_handle = samsync_state->domain_handle[database_id]; @@ -384,7 +386,7 @@ static BOOL samsync_handle_policy(TALLOC_CTX *mem_ctx, struct samsync_state *sam printf("\tsequence_nums[%d/PRIVS]=%llu\n", database_id, - samsync_state->seq_num[database_id]); + (long long)samsync_state->seq_num[database_id]); return True; } diff --git a/source4/torture/smb2/connect.c b/source4/torture/smb2/connect.c index 4973dcee6f..dde2ace4b2 100644 --- a/source4/torture/smb2/connect.c +++ b/source4/torture/smb2/connect.c @@ -51,8 +51,8 @@ static NTSTATUS torture_smb2_close(struct smb2_tree *tree, struct smb2_handle ha printf("access_time = %s\n", nt_time_string(tmp_ctx, io.out.access_time)); printf("write_time = %s\n", nt_time_string(tmp_ctx, io.out.write_time)); printf("change_time = %s\n", nt_time_string(tmp_ctx, io.out.change_time)); - printf("alloc_size = %lld\n", io.out.alloc_size); - printf("size = %lld\n", io.out.size); + printf("alloc_size = %lld\n", (long long)io.out.alloc_size); + printf("size = %lld\n", (long long)io.out.size); printf("file_attr = 0x%x\n", io.out.file_attr); } @@ -170,12 +170,12 @@ static struct smb2_handle torture_smb2_create(struct smb2_tree *tree, printf("access_time = %s\n", nt_time_string(tmp_ctx, io.out.access_time)); printf("write_time = %s\n", nt_time_string(tmp_ctx, io.out.write_time)); printf("change_time = %s\n", nt_time_string(tmp_ctx, io.out.change_time)); - printf("alloc_size = %lld\n", io.out.alloc_size); - printf("size = %lld\n", io.out.size); + printf("alloc_size = %lld\n", (long long)io.out.alloc_size); + printf("size = %lld\n", (long long)io.out.size); printf("file_attr = 0x%x\n", io.out.file_attr); printf("handle = %016llx%016llx\n", - io.out.handle.data[0], - io.out.handle.data[1]); + (long long)io.out.handle.data[0], + (long long)io.out.handle.data[1]); } talloc_free(tmp_ctx); diff --git a/source4/torture/smb2/scan.c b/source4/torture/smb2/scan.c index b0c4ba4c8d..03aa6dca49 100644 --- a/source4/torture/smb2/scan.c +++ b/source4/torture/smb2/scan.c @@ -78,8 +78,8 @@ BOOL torture_smb2_getinfo_scan(void) if (!NT_STATUS_EQUAL(status, NT_STATUS_INVALID_INFO_CLASS) && !NT_STATUS_EQUAL(status, NT_STATUS_INVALID_PARAMETER) && !NT_STATUS_EQUAL(status, NT_STATUS_NOT_SUPPORTED)) { - printf("file level 0x%04x is %d bytes - %s\n", - io.in.level, io.out.blob.length, nt_errstr(status)); + printf("file level 0x%04x is %ld bytes - %s\n", + io.in.level, (long)io.out.blob.length, nt_errstr(status)); dump_data(1, io.out.blob.data, io.out.blob.length); } @@ -88,8 +88,8 @@ BOOL torture_smb2_getinfo_scan(void) if (!NT_STATUS_EQUAL(status, NT_STATUS_INVALID_INFO_CLASS) && !NT_STATUS_EQUAL(status, NT_STATUS_INVALID_PARAMETER) && !NT_STATUS_EQUAL(status, NT_STATUS_NOT_SUPPORTED)) { - printf("dir level 0x%04x is %d bytes - %s\n", - io.in.level, io.out.blob.length, nt_errstr(status)); + printf("dir level 0x%04x is %ld bytes - %s\n", + io.in.level, (long)io.out.blob.length, nt_errstr(status)); dump_data(1, io.out.blob.data, io.out.blob.length); } } @@ -183,8 +183,8 @@ BOOL torture_smb2_find_scan(void) if (!NT_STATUS_EQUAL(status, NT_STATUS_INVALID_INFO_CLASS) && !NT_STATUS_EQUAL(status, NT_STATUS_INVALID_PARAMETER) && !NT_STATUS_EQUAL(status, NT_STATUS_NOT_SUPPORTED)) { - printf("find level 0x%04x is %d bytes - %s\n", - io.in.level, io.out.blob.length, nt_errstr(status)); + printf("find level 0x%04x is %ld bytes - %s\n", + io.in.level, (long)io.out.blob.length, nt_errstr(status)); dump_data(1, io.out.blob.data, io.out.blob.length); } } diff --git a/source4/torture/smb2/util.c b/source4/torture/smb2/util.c index 886aaea09f..a3d6ed8d66 100644 --- a/source4/torture/smb2/util.c +++ b/source4/torture/smb2/util.c @@ -224,16 +224,16 @@ void torture_smb2_all_info(struct smb2_tree *tree, struct smb2_handle handle) d_printf("\tchange_time: %s\n", nt_time_string(tmp_ctx, io.all_info2.out.change_time)); d_printf("\tattrib: 0x%x\n", io.all_info2.out.attrib); d_printf("\tunknown1: 0x%x\n", io.all_info2.out.unknown1); - d_printf("\talloc_size: %llu\n", (uint64_t)io.all_info2.out.alloc_size); - d_printf("\tsize: %llu\n", (uint64_t)io.all_info2.out.size); + d_printf("\talloc_size: %llu\n", (long long)io.all_info2.out.alloc_size); + d_printf("\tsize: %llu\n", (long long)io.all_info2.out.size); d_printf("\tnlink: %u\n", io.all_info2.out.nlink); d_printf("\tdelete_pending: %u\n", io.all_info2.out.delete_pending); d_printf("\tdirectory: %u\n", io.all_info2.out.directory); - d_printf("\tfile_id: %llu\n", io.all_info2.out.file_id); + d_printf("\tfile_id: %llu\n", (long long)io.all_info2.out.file_id); d_printf("\tea_size: %u\n", io.all_info2.out.ea_size); d_printf("\taccess_mask: 0x%08x\n", io.all_info2.out.access_mask); - d_printf("\tposition: 0x%llx\n", io.all_info2.out.position); - d_printf("\tmode: 0x%llx\n", io.all_info2.out.mode); + d_printf("\tposition: 0x%llx\n", (long long)io.all_info2.out.position); + d_printf("\tmode: 0x%llx\n", (long long)io.all_info2.out.mode); /* short name, if any */ io.generic.level = RAW_FILEINFO_ALT_NAME_INFORMATION; diff --git a/source4/torture/torture_util.c b/source4/torture/torture_util.c index 4606ec6840..cdc0155ecc 100644 --- a/source4/torture/torture_util.c +++ b/source4/torture/torture_util.c @@ -318,8 +318,8 @@ void dump_all_info(TALLOC_CTX *mem_ctx, union smb_fileinfo *finfo) d_printf("\twrite_time: %s\n", nt_time_string(mem_ctx, finfo->all_info.out.write_time)); d_printf("\tchange_time: %s\n", nt_time_string(mem_ctx, finfo->all_info.out.change_time)); d_printf("\tattrib: 0x%x\n", finfo->all_info.out.attrib); - d_printf("\talloc_size: %llu\n", (uint64_t)finfo->all_info.out.alloc_size); - d_printf("\tsize: %llu\n", (uint64_t)finfo->all_info.out.size); + d_printf("\talloc_size: %llu\n", (long long)finfo->all_info.out.alloc_size); + d_printf("\tsize: %llu\n", (long long)finfo->all_info.out.size); d_printf("\tnlink: %u\n", finfo->all_info.out.nlink); d_printf("\tdelete_pending: %u\n", finfo->all_info.out.delete_pending); d_printf("\tdirectory: %u\n", finfo->all_info.out.directory); |