Fixed CE on 32-bit platforms

This commit is contained in:
vvaltman 2014-08-31 21:19:56 +04:00
parent c1fa31c3d7
commit f51f3b4da3
2 changed files with 3 additions and 3 deletions

View file

@ -229,7 +229,7 @@ void tglq_query_error (long long id) {
static int packed_buffer[MAX_PACKED_SIZE / 4];
void tglq_query_result (long long id UU) {
vlogprintf (E_DEBUG, "result for query #%lld. Size %ld bytes\n", id, 4 * (in_end - in_ptr));
vlogprintf (E_DEBUG, "result for query #%lld. Size %ld bytes\n", id, (long)4 * (in_end - in_ptr));
/*if (verbosity >= 4) {
logprintf ( "result: ");
hexdump_in ();
@ -270,7 +270,7 @@ void tglq_query_result (long long id UU) {
int *save = in_ptr;
vlogprintf (E_DEBUG, "in_ptr = %p, end_ptr = %p\n", in_ptr, in_end);
if (skip_type_any (q->methods->type) < 0) {
vlogprintf (E_ERROR, "Skipped %ld int out of %ld (type %s)\n", in_ptr - save, in_end - save, q->methods->type->type->id);
vlogprintf (E_ERROR, "Skipped %ld int out of %ld (type %s)\n", (long)(in_ptr - save), (long)(in_end - save), q->methods->type->type->id);
assert (0);
}

View file

@ -1178,7 +1178,7 @@ void tglf_fetch_encrypted_message (struct tgl_message *M) {
} else {
start = in_ptr;
if (skip_type_any (TYPE_TO_PARAM (decrypted_message_action)) < 0) {
vlogprintf (E_ERROR, "Skipped %ld int out of %ld. Magic = 0x%08x\n", in_ptr - start, in_end - start, *start);
vlogprintf (E_ERROR, "Skipped %ld int out of %ld. Magic = 0x%08x\n", (long)(in_ptr - start), (long)(in_end - start), *start);
assert (0);
}
end = in_ptr;