summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2009-10-03 22:41:12 -0700
committerSven Gothel <[email protected]>2009-10-03 22:41:12 -0700
commit675ee156d70463f25c766e13547e0c22f19e3eac (patch)
tree32ac22ec0f4eda79b2899e083c25d4da5ba7b3ef
parentbf584fba26561a1905f37251d681ac100d4a0779 (diff)
Avoid NPE if no context current
-rw-r--r--src/jogl/classes/com/sun/opengl/impl/GLDrawableImpl.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/jogl/classes/com/sun/opengl/impl/GLDrawableImpl.java b/src/jogl/classes/com/sun/opengl/impl/GLDrawableImpl.java
index 020bea9f0..865abe09f 100644
--- a/src/jogl/classes/com/sun/opengl/impl/GLDrawableImpl.java
+++ b/src/jogl/classes/com/sun/opengl/impl/GLDrawableImpl.java
@@ -78,7 +78,7 @@ public abstract class GLDrawableImpl implements GLDrawable {
}
} else {
GLContext ctx = GLContext.getCurrent();
- if(ctx.getGLDrawable()==this) {
+ if(null!=ctx && ctx.getGLDrawable()==this) {
ctx.getGL().glFinish();
}
}