Commit abcc536b by shrekshao Committed by Commit Bot

Speculative fix for nullptr program in QueryProgramiv

It is reported that an increase crash rate is seen on M81. This is a speculative fix based on that most crashes have calls from GrGLProgramBuilder::checkLinkStatus. Bug: chromium:991020 Change-Id: I549de9e0a0cccde8b9c68d706828963fe3f9bdf2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2095596Reviewed-by: 's avatarJonah Ryan-Davis <jonahr@google.com> Reviewed-by: 's avatarShrek Shao <shrekshao@google.com> Commit-Queue: Shrek Shao <shrekshao@google.com>
parent 5d7ccc30
...@@ -1195,7 +1195,7 @@ void QueryProgramiv(Context *context, const Program *program, GLenum pname, GLin ...@@ -1195,7 +1195,7 @@ void QueryProgramiv(Context *context, const Program *program, GLenum pname, GLin
*params = program->isFlaggedForDeletion(); *params = program->isFlaggedForDeletion();
return; return;
case GL_LINK_STATUS: case GL_LINK_STATUS:
*params = program->isLinked(); *params = program ? program->isLinked() : false;
return; return;
case GL_COMPLETION_STATUS_KHR: case GL_COMPLETION_STATUS_KHR:
if (context->isContextLost()) if (context->isContextLost())
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment