Skip to content

Commit

Permalink
ADLMIDI2: Backport minor fix from official ADLMIDI
Browse files Browse the repository at this point in the history
Change setbuffer to setvbuf, fixing PR2 / issue 2.
bisqwit/adlmidi@2f3a626
  • Loading branch information
Wohlstand committed Dec 4, 2018
1 parent ed474f4 commit d89084d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils/adlmidi-2/midiplay.cc
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ static class UserInterface
std::memset(background, '.', sizeof(background));
std::memset(backgroundcolor, 1, sizeof(backgroundcolor));
#ifndef _WIN32
setbuffer(stderr, stderr_buffer, sizeof(stderr_buffer));
std::setvbuf(stderr, stderr_buffer, _IOFBF, sizeof(stderr_buffer));
#endif
RawPrn("\r"); // Ensure cursor is at the x=0 we imagine it being
Print(0, 7, true, "Hit Ctrl-C to quit");
Expand Down

0 comments on commit d89084d

Please sign in to comment.