NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
bin/49716: Use false and true on bool in midirecord.c
>Number: 49716
>Category: bin
>Synopsis: Use false and true on bool in midirecord.c
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: bin-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Mar 04 12:20:00 +0000 2015
>Originator: Henning Petersen
>Release: NetBSD-current
>Organization:
>Environment:
>Description:
Use false and true on debug.
Use correct fprintf format.
>How-To-Repeat:
>Fix:
diff -u -p -r1.7 midirecord.c
--- usr.bin/midirecord/midirecord.c 1 Mar 2015 09:56:54 -0000 1.7
+++ usr.bin/midirecord/midirecord.c 4 Mar 2015 12:00:21 -0000
@@ -122,7 +122,7 @@ main(int argc, char *argv[])
"channels");
break;
case 'D':
- debug++;
+ debug = true;
break;
case 'd':
parse_ints(optarg, &filt_devnos, &num_filt_devnos,
@@ -237,7 +237,7 @@ main(int argc, char *argv[])
data_size = 0;
if (verbose)
- fprintf(stderr, "tempo=%d notes_per_beat=%d\n",
+ fprintf(stderr, "tempo=%d notes_per_beat=%u\n",
tempo, notes_per_beat);
if (!no_time_limit && verbose)
@@ -282,7 +282,7 @@ debug_log(const char *file, size_t line,
if (!debug)
return;
- fprintf(stderr, "%s:%zd: ", file, line);
+ fprintf(stderr, "%s:%zu: ", file, line);
va_start(ap, fmt);
vfprintf(stderr, fmt, ap);
va_end(ap);
Home |
Main Index |
Thread Index |
Old Index