Previous 199869 Revisions Next

r34139 Thursday 1st January, 2015 at 14:15:03 UTC by Oliver Stöneberg
fixed yet another data race warning (nw)
[src/osd/sdl]sdlwork.c
[src/osd/windows]winwork.c

trunk/src/osd/sdl/sdlwork.c
r242650r242651
690690   begin_timing(thread->runtime);
691691
692692   // loop until everything is processed
693   while (queue->list != NULL)
693   while (true)
694694   {
695695      osd_work_item *item;
696      INT32 lockslot;
697696
698697      // use a critical section to synchronize the removal of items
699      lockslot = osd_scalable_lock_acquire(queue->lock);
698      INT32 lockslot = osd_scalable_lock_acquire(queue->lock);
700699      {
700         if (queue->list == NULL)
701         {
702            osd_scalable_lock_release(queue->lock, lockslot);
703            break;
704         }
705         
706
701707         // pull the item from the queue
702708         item = (osd_work_item *)queue->list;
703709         if (item != NULL)
trunk/src/osd/windows/winwork.c
r242650r242651
681681   begin_timing(thread->runtime);
682682
683683   // loop until everything is processed
684   while (queue->list != NULL)
684   while (true)
685685   {
686686      osd_work_item *item;
687      INT32 lockslot;
688687
689688      // use a critical section to synchronize the removal of items
690      lockslot = osd_scalable_lock_acquire(queue->lock);
689      INT32 lockslot = osd_scalable_lock_acquire(queue->lock);
691690      {
691         if (queue->list == NULL)
692         {
693            osd_scalable_lock_release(queue->lock, lockslot);
694            break;
695         }
696         
697
692698         // pull the item from the queue
693699         item = (osd_work_item *)queue->list;
694700         if (item != NULL)


Previous 199869 Revisions Next


© 1997-2024 The MAME Team