Skip to content

Commit

Permalink
Bug 927: Try fix deadlock.
Browse files Browse the repository at this point in the history
(14:15:13) sgothel: @XERXES: In doResume .. do a 'while( !isActive && !shallPause && isRunning ) {'
(14:15:52) sgothel: doPause: while( isActive && !shallPause && isRunning )
(14:31:55) sgothel: doPause only: while( isActive && isRunning ) {
  • Loading branch information
xranby committed Feb 25, 2014
1 parent c67de33 commit ac7de4a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/jogl/classes/jogamp/opengl/util/av/GLMediaPlayerImpl.java
Expand Up @@ -1127,7 +1127,7 @@ public final synchronized void doPause() {
if( isBlocked && isActive ) {
this.interrupt();
}
while( isActive ) {
while( isActive && isRunning ) {
try {
this.wait(); // wait until paused
} catch (InterruptedException e) {
Expand All @@ -1141,7 +1141,7 @@ public final synchronized void doResume() {
if( isRunning && !isActive ) {
shallPause = false;
if( Thread.currentThread() != this ) {
while( !isActive ) {
while( !isActive && !shallPause && isRunning ) {
this.notifyAll(); // wake-up pause-block
try {
this.wait(); // wait until resumed
Expand Down

0 comments on commit ac7de4a

Please sign in to comment.