1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-12 09:18:10 +03:00

r19013: Fix some 64-bit warnings.

Jelmer, Jerry, in cmd_unixinfo.c:159 there is still the warning that "info" is
being used uninitialized which I don't really know how to fix.

Any hints?

Volker
(This used to be commit 4a5d11e194)
This commit is contained in:
Volker Lendecke 2006-09-30 17:32:26 +00:00 committed by Gerald (Jerry) Carter
parent 69287da633
commit bb5c820542
3 changed files with 11 additions and 10 deletions

View File

@ -63,9 +63,9 @@ static void display_query_info_1(DOM_QUERY_1 d)
{
d_printf("percent_full:\t%d\n", d.percent_full);
d_printf("log_size:\t%d\n", d.log_size);
d_printf("retention_time:\t%lld\n", d.retention_time);
d_printf("retention_time:\t%lld\n", (long long)d.retention_time);
d_printf("shutdown_in_progress:\t%d\n", d.shutdown_in_progress);
d_printf("time_to_shutdown:\t%lld\n", d.time_to_shutdown);
d_printf("time_to_shutdown:\t%lld\n", (long long)d.time_to_shutdown);
d_printf("next_audit_record:\t%d\n", d.next_audit_record);
d_printf("unknown:\t%d\n", d.unknown);
}

View File

@ -165,7 +165,7 @@ static void display_sam_unk_info_2(SAM_UNK_INFO_2 *info2)
printf("Total Groups:\t%d\n", info2->num_domain_grps);
printf("Total Aliases:\t%d\n", info2->num_local_grps);
printf("Sequence No:\t%lld\n", info2->seq_num);
printf("Sequence No:\t%llu\n", (unsigned long long)info2->seq_num);
printf("Force Logoff:\t%d\n", (int)nt_time_to_unix_abs(&info2->logout));
@ -210,7 +210,7 @@ static void display_sam_unk_info_7(SAM_UNK_INFO_7 *info7)
static void display_sam_unk_info_8(SAM_UNK_INFO_8 *info8)
{
printf("Sequence No:\t%lld\n", info8->seq_num);
printf("Sequence No:\t%llu\n", (unsigned long long)info8->seq_num);
printf("Domain Create Time:\t%s\n",
http_timestring(nt_time_to_unix(info8->domain_create_time)));
}
@ -229,7 +229,7 @@ static void display_sam_unk_info_12(SAM_UNK_INFO_12 *info12)
static void display_sam_unk_info_13(SAM_UNK_INFO_13 *info13)
{
printf("Sequence No:\t%lld\n", info13->seq_num);
printf("Sequence No:\t%llu\n", (unsigned long long)info13->seq_num);
printf("Domain Create Time:\t%s\n",
http_timestring(nt_time_to_unix(info13->domain_create_time)));
printf("Unknown1:\t%d\n", info13->unknown1);

View File

@ -70,7 +70,7 @@ static NTSTATUS cmd_unixinfo_sid2uid(struct rpc_pipe_client *cli,
if (!NT_STATUS_IS_OK(result))
goto done;
printf("%llu\n", uid);
printf("%llu\n", (unsigned long long)uid);
done:
return result;
@ -125,7 +125,7 @@ static NTSTATUS cmd_unixinfo_sid2gid(struct rpc_pipe_client *cli,
if (!NT_STATUS_IS_OK(result))
goto done;
printf("%llu\n", gid);
printf("%llu\n", (unsigned long long)gid);
done:
return result;
@ -164,10 +164,11 @@ static NTSTATUS cmd_unixinfo_getpwuid(struct rpc_pipe_client *cli,
for (i=0; i<num_uids; i++) {
if (NT_STATUS_IS_OK(info[i].status)) {
printf("%llu:%s:%s\n", uids[i], info[i].homedir,
info[i].shell);
printf("%llu:%s:%s\n", (unsigned long long)uids[i],
info[i].homedir, info[i].shell);
} else {
printf("%llu:%s\n", uids[i], nt_errstr(info[i].status));
printf("%llu:%s\n", (unsigned long long)uids[i],
nt_errstr(info[i].status));
}
}