Browse Source

Fix usage of RtList::getFirst()

tags/1.9.4
falkTX 12 years ago
parent
commit
3cfc858e2b
4 changed files with 4 additions and 4 deletions
  1. +1
    -1
      source/backend/engine/CarlaEngineRtAudio.cpp
  2. +1
    -1
      source/backend/plugin/DssiPlugin.cpp
  3. +1
    -1
      source/backend/plugin/NativePlugin.cpp
  4. +1
    -1
      source/utils/RtList.hpp

+ 1
- 1
source/backend/engine/CarlaEngineRtAudio.cpp View File

@@ -316,7 +316,7 @@ protected:


while (! fMidiInEvents.data.isEmpty()) while (! fMidiInEvents.data.isEmpty())
{ {
const RtMidiEvent& midiEvent = fMidiInEvents.data.getLast(true);
const RtMidiEvent& midiEvent = fMidiInEvents.data.getFirst(true);


EngineEvent* const engineEvent = &kData->rack.in[engineEventIndex++]; EngineEvent* const engineEvent = &kData->rack.in[engineEventIndex++];
engineEvent->clear(); engineEvent->clear();


+ 1
- 1
source/backend/plugin/DssiPlugin.cpp View File

@@ -952,7 +952,7 @@ public:
{ {
while (midiEventCount < MAX_MIDI_EVENTS && ! kData->extNotes.data.isEmpty()) while (midiEventCount < MAX_MIDI_EVENTS && ! kData->extNotes.data.isEmpty())
{ {
const ExternalMidiNote& note = kData->extNotes.data.getLast(true); // FIXME, should be first
const ExternalMidiNote& note = kData->extNotes.data.getFirst(true);


CARLA_ASSERT(note.channel >= 0); CARLA_ASSERT(note.channel >= 0);




+ 1
- 1
source/backend/plugin/NativePlugin.cpp View File

@@ -1056,7 +1056,7 @@ public:
{ {
while (fMidiEventCount < MAX_MIDI_EVENTS*2 && ! kData->extNotes.data.isEmpty()) while (fMidiEventCount < MAX_MIDI_EVENTS*2 && ! kData->extNotes.data.isEmpty())
{ {
const ExternalMidiNote& note = kData->extNotes.data.getLast(true); // FIXME, should be first
const ExternalMidiNote& note = kData->extNotes.data.getFirst(true);


CARLA_ASSERT(note.channel >= 0); CARLA_ASSERT(note.channel >= 0);




+ 1
- 1
source/utils/RtList.hpp View File

@@ -239,7 +239,7 @@ private:
if (fCount == 0) if (fCount == 0)
return _retEmpty(); return _retEmpty();


k_list_head* const entry = first ? fQueue.prev : fQueue.next;
k_list_head* const entry = first ? fQueue.next : fQueue.prev;
Data* const data = list_entry(entry, Data, siblings); Data* const data = list_entry(entry, Data, siblings);


CARLA_ASSERT(data != nullptr); CARLA_ASSERT(data != nullptr);


Loading…
Cancel
Save