--- deliantra/Deliantra-Client/DC.pm 2006/05/19 03:49:47 1.54 +++ deliantra/Deliantra-Client/DC.pm 2006/05/19 23:18:40 1.56 @@ -52,7 +52,7 @@ return unless $GL_DEBUG; if (my $error = glGetError) { - Carp::cluck sprintf "opengl error %x while %s", $error, sprintf @_; + Carp::cluck sprintf "opengl error %x while %s", $error, &sprintf(@_); } } @@ -373,6 +373,8 @@ CFClient::gl_check "copying to texture %dx%d if=%x", $tw, $th, $self->{internalformat}; } + + glBindTexture GL_TEXTURE_2D, 0; # just to be on the safe side } sub DESTROY {