Fix incorrect string format causing crashes on 32-bit systems

Fixes #252
This commit is contained in:
Michael Gratton 2019-02-21 10:33:56 +11:00
parent 579c6d3b5e
commit c62a22abe8
2 changed files with 4 additions and 4 deletions

View file

@ -107,8 +107,8 @@ private class Geary.ImapEngine.ReplayRemoval : Geary.ImapEngine.ReplayOperation
this.owner.replay_queue.notify_remote_removed_ids(
Geary.iterate<ImapDB.EmailIdentifier>(owned_id).to_array_list());
} else {
debug("%s do_replay_removed_message: this.position=%ld unknown in local store "
+ "(this.remote_count=%d local_position=%ld local_count=%d)",
debug("%s do_replay_removed_message: this.position=%lld unknown in local store "
+ "(this.remote_count=%d local_position=%lld local_count=%d)",
to_string(), this.position.value, this.remote_count, local_position, local_count);
}
@ -148,7 +148,7 @@ private class Geary.ImapEngine.ReplayRemoval : Geary.ImapEngine.ReplayOperation
}
debug("%s ReplayRemoval: completed, "
+ "(this.remote_count=%d local_count=%d starting local_count=%d this.position=%ld local_position=%ld marked=%s)",
+ "(this.remote_count=%d local_count=%d starting local_count=%d this.position=%lld local_position=%lld marked=%s)",
this.owner.to_string(),
this.remote_count, new_local_count, local_count,
this.position.value, local_position, marked.to_string());

View file

@ -81,7 +81,7 @@ namespace Geary.Stream {
double pct = (converted_bytes_read > converted_bytes_written)
? (double) converted_bytes_written / (double) converted_bytes_read
: (double) converted_bytes_read / (double) converted_bytes_written;
debug("%s read/written: %s/%s (%ld%%)", name, converted_bytes_read.to_string(),
debug("%s read/written: %s/%s (%lld%%)", name, converted_bytes_read.to_string(),
converted_bytes_written.to_string(), (long) (pct * 100.0));
}