LenShustek/miditones

Runs, but cannot read tracks when compiled on linux (x64)

GoogleCodeExporter opened this issue · 3 comments

Compiling with gcc 4.7.3 on Mint(Ubuntu) linux amd64 will succeed if you 
substitute srtcat/strcpy for the secure variations and drop the extra 
parameters.  Compiling with -Wformat flag will generate a binary which appears 
to work but cannot read midi tracks, though everything else seems to work when 
run with input parsing logging enabled.  I'm not a C guru but I think we have a 
problem with pointers?

Here is the output without the -Wformat flag

$ gcc miditonesV1.4.c -o miditones

miditonesV1.4.c: In function ‘midi_error’:
miditonesV1.4.c:353:5: warning: format ‘%X’ expects argument of type 
‘unsigned int’, but argument 3 has type ‘long int’ [-Wformat]
miditonesV1.4.c:353:5: warning: format ‘%d’ expects argument of type 
‘int’, but argument 4 has type ‘long int’ [-Wformat]
miditonesV1.4.c: In function ‘start_track’:
miditonesV1.4.c:432:5: warning: format ‘%d’ expects argument of type 
‘int’, but argument 4 has type ‘long unsigned int’ [-Wformat]
miditonesV1.4.c: In function ‘find_note’:
miditonesV1.4.c:482:13: warning: format ‘%d’ expects argument of type 
‘int’, but argument 3 has type ‘long unsigned int’ [-Wformat]
miditonesV1.4.c: In function ‘main’:
miditonesV1.4.c:780:17: warning: format ‘%d’ expects argument of type 
‘int’, but argument 3 has type ‘long unsigned int’ [-Wformat]
miditonesV1.4.c:780:17: warning: format ‘%d’ expects argument of type 
‘int’, but argument 4 has type ‘long unsigned int’ [-Wformat]
miditonesV1.4.c:882:9: warning: format ‘%d’ expects argument of type 
‘int’, but argument 2 has type ‘long int’ [-Wformat]

I thought I could do a quick port but alas, my C is weak.  I'd really love to 
see it work though.

Original issue reported on code.google.com by guiltypi...@gmail.com on 3 Aug 2013 at 5:25

Fixed in version 1.6.

Original comment by Len.Shus...@gmail.com on 31 Dec 2013 at 12:02

  • Changed state: Accepted
  • Added labels: ****
  • Removed labels: ****
The change for this is done now.

Original comment by Len.Shus...@gmail.com on 31 Dec 2013 at 12:03

  • Changed state: Fixed
  • Added labels: ****
  • Removed labels: ****
Fixed in version 1.6.

Original comment by Len.Shus...@gmail.com on 31 Dec 2013 at 12:02

  • Added labels: ****
  • Removed labels: ****