提交 61c6defd 编写于 作者: J jp9000

almost lured myself into another null pointer trap, fixed

上级 31dd23cb
......@@ -247,7 +247,7 @@ void device_load_texture(device_t device, texture_t tex, int unit)
if (!gl_active_texture(GL_TEXTURE0 + unit))
goto fail;
if (!tex || (cur_tex && cur_tex->gl_target != tex->gl_target))
if (cur_tex && (!tex || cur_tex->gl_target != tex->gl_target))
gl_bind_texture(cur_tex->gl_target, 0);
device->cur_textures[unit] = tex;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册