mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-05 03:24:56 +08:00
ref: gl: only check for GL errors if both gl_check_errors and developer mode are enabled
This commit is contained in:
@@ -1351,12 +1351,12 @@ obsolete
|
||||
*/
|
||||
void GL_CheckForErrors_( const char *filename, const int fileline )
|
||||
{
|
||||
int err;
|
||||
|
||||
if( !gl_check_errors.value )
|
||||
if( !gl_check_errors.value || !gpGlobals->developer )
|
||||
return;
|
||||
|
||||
if(( err = pglGetError( )) == GL_NO_ERROR )
|
||||
int err = pglGetError( );
|
||||
|
||||
if( err == GL_NO_ERROR )
|
||||
return;
|
||||
|
||||
gEngfuncs.Con_Printf( S_OPENGL_ERROR "%s (at %s:%i)\n", GL_ErrorString( err ), filename, fileline );
|
||||
|
||||
Reference in New Issue
Block a user