mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-21 18:38:08 +01:00
fix wrong printf formatting of signed/unsigned integers
This commit is contained in:
parent
410b96080c
commit
85c8304058
4 changed files with 5 additions and 5 deletions
|
@ -111,7 +111,7 @@ print_count (notmuch_database_t *notmuch, const char *query_str,
|
||||||
case OUTPUT_FILES:
|
case OUTPUT_FILES:
|
||||||
count = count_files (query);
|
count = count_files (query);
|
||||||
if (count >= 0) {
|
if (count >= 0) {
|
||||||
printf ("%u", count);
|
printf ("%d", count);
|
||||||
} else {
|
} else {
|
||||||
ret = -1;
|
ret = -1;
|
||||||
goto DONE;
|
goto DONE;
|
||||||
|
|
|
@ -131,10 +131,10 @@ generic_print_progress (const char *action, const char *object,
|
||||||
elapsed_overall = notmuch_time_elapsed (tv_start, tv_now);
|
elapsed_overall = notmuch_time_elapsed (tv_start, tv_now);
|
||||||
rate_overall = processed / elapsed_overall;
|
rate_overall = processed / elapsed_overall;
|
||||||
|
|
||||||
printf ("%s %d ", action, processed);
|
printf ("%s %u ", action, processed);
|
||||||
|
|
||||||
if (total) {
|
if (total) {
|
||||||
printf ("of %d %s", total, object);
|
printf ("of %u %s", total, object);
|
||||||
if (processed > 0 && elapsed_overall > 0.5) {
|
if (processed > 0 && elapsed_overall > 0.5) {
|
||||||
double time_remaining = ((total - processed) / rate_overall);
|
double time_remaining = ((total - processed) / rate_overall);
|
||||||
printf (" (");
|
printf (" (");
|
||||||
|
|
|
@ -635,7 +635,7 @@ static int do_reply(notmuch_config_t *config,
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
if (count != 1) {
|
if (count != 1) {
|
||||||
fprintf (stderr, "Error: search term did not match precisely one message (matched %d messages).\n", count);
|
fprintf (stderr, "Error: search term did not match precisely one message (matched %u messages).\n", count);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -902,7 +902,7 @@ do_show_single (void *ctx,
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
if (count != 1) {
|
if (count != 1) {
|
||||||
fprintf (stderr, "Error: search term did not match precisely one message (matched %d messages).\n", count);
|
fprintf (stderr, "Error: search term did not match precisely one message (matched %u messages).\n", count);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue