WriteFile requires 4th parameter
Fixes crashes on certain versions of Windows.
This commit is contained in:
parent
b4701b6c91
commit
fee18df791
2 changed files with 4 additions and 2 deletions
|
|
@ -161,8 +161,9 @@ static boolean MidiPipe_RegisterSong(buffer_reader_t *reader)
|
|||
buffer[0] = (i >> 8) & 0xff;
|
||||
buffer[1] = i & 0xff;
|
||||
|
||||
DWORD bytes_written;
|
||||
WriteFile(midi_process_out, buffer, sizeof(buffer),
|
||||
NULL, NULL);
|
||||
&bytes_written, NULL);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -127,8 +127,9 @@ static boolean UsingNativeMidi()
|
|||
//
|
||||
static boolean WritePipe(net_packet_t *packet)
|
||||
{
|
||||
DWORD bytes_written;
|
||||
BOOL ok = WriteFile(midi_process_in_writer, packet->data, packet->len,
|
||||
NULL, NULL);
|
||||
&bytes_written, NULL);
|
||||
|
||||
if (!ok)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue