javax.media.opengl.GLException: Context not current

I’m playing around with QtJambi. For some reason I receive a


javax.media.opengl.GLException: Context not current

when I call glTexImage2D. It doesn’t seem to complain when I call glGenTexture and seems to give me a valid handle.

I found a similar issue here but he/she never got a response. Also, that was back in 2006 so if it was a bug, I would it is resolved by now.

Has anyone experienced this exception? I make a texture handle right before it and do some GL drawing right after it (if I comment it out).