Browse Source

Update WinMME driver for 64 bits compilation.

git-svn-id: http://subversion.jackaudio.org/jack/jack2/trunk/jackmp@4289 0c269be4-1314-0410-8aa9-9f06e86f4224
tags/1.9.8
sletz 14 years ago
parent
commit
87af94ddfc
3 changed files with 9 additions and 8 deletions
  1. +5
    -4
      common/JackControlAPI.cpp
  2. +2
    -2
      windows/winmme/JackWinMMEInputPort.cpp
  3. +2
    -2
      windows/winmme/JackWinMMEOutputPort.cpp

+ 5
- 4
common/JackControlAPI.cpp View File

@@ -1236,13 +1236,14 @@ EXPORT bool jackctl_server_remove_slave(jackctl_server * server_ptr, jackctl_dri
if (server_ptr->engine->IsRunning()) { if (server_ptr->engine->IsRunning()) {
jack_error("cannot remove a slave from a running server"); jack_error("cannot remove a slave from a running server");
return false; return false;
} else {
JackDriverInfo* info = (JackDriverInfo*)driver_ptr->infos->data;
if (info) {
} else {
if (driver_ptr->infos) {
JackDriverInfo* info = (JackDriverInfo*)driver_ptr->infos->data;
assert(info);
driver_ptr->infos = jack_slist_remove(driver_ptr->infos, info); driver_ptr->infos = jack_slist_remove(driver_ptr->infos, info);
server_ptr->engine->RemoveSlave(info); server_ptr->engine->RemoveSlave(info);
delete info; delete info;
return true;
return true;
} else { } else {
return false; return false;
} }


+ 2
- 2
windows/winmme/JackWinMMEInputPort.cpp View File

@@ -55,8 +55,8 @@ JackWinMMEInputPort::JackWinMMEInputPort(const char *alias_name,
std::auto_ptr<JackMidiBufferWriteQueue> write_queue_ptr(write_queue); std::auto_ptr<JackMidiBufferWriteQueue> write_queue_ptr(write_queue);
sysex_buffer = new jack_midi_data_t[max_bytes]; sysex_buffer = new jack_midi_data_t[max_bytes];
char error_message[MAXERRORLENGTH]; char error_message[MAXERRORLENGTH];
MMRESULT result = midiInOpen(&handle, index, (DWORD)HandleMidiInputEvent,
(DWORD)this,
MMRESULT result = midiInOpen(&handle, index, (DWORD_PTR)HandleMidiInputEvent,
(DWORD_PTR)this,
CALLBACK_FUNCTION | MIDI_IO_STATUS); CALLBACK_FUNCTION | MIDI_IO_STATUS);
if (result != MMSYSERR_NOERROR) { if (result != MMSYSERR_NOERROR) {
GetInErrorString(result, error_message); GetInErrorString(result, error_message);


+ 2
- 2
windows/winmme/JackWinMMEOutputPort.cpp View File

@@ -55,8 +55,8 @@ JackWinMMEOutputPort::JackWinMMEOutputPort(const char *alias_name,
thread = new JackThread(this); thread = new JackThread(this);
std::auto_ptr<JackThread> thread_ptr(thread); std::auto_ptr<JackThread> thread_ptr(thread);
char error_message[MAXERRORLENGTH]; char error_message[MAXERRORLENGTH];
MMRESULT result = midiOutOpen(&handle, index, (DWORD)HandleMessageEvent,
(DWORD)this, CALLBACK_FUNCTION);
MMRESULT result = midiOutOpen(&handle, index, (DWORD_PTR)HandleMessageEvent,
(DWORD_PTR)this, CALLBACK_FUNCTION);
if (result != MMSYSERR_NOERROR) { if (result != MMSYSERR_NOERROR) {
GetOutErrorString(result, error_message); GetOutErrorString(result, error_message);
goto raise_exception; goto raise_exception;


Loading…
Cancel
Save