From 63cf0e11adcb37bd34a029474ec8d0723687effa Mon Sep 17 00:00:00 2001 From: "apatrick@google.com" Date: Fri, 4 Jan 2013 23:29:35 +0000 Subject: Merge 175106 > Fix crash when translated ANGLE shader source has length zero. > > BUG=153048 > > Review URL: https://chromiumcodereview.appspot.com/11770002 TBR=apatrick@chromium.org Review URL: https://codereview.chromium.org/11783005 git-svn-id: svn://svn.chromium.org/chrome/branches/1364/src@175232 0039d316-1c4b-4281-b951-d872f2087c98 --- gpu/command_buffer/service/program_manager.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gpu/command_buffer/service/program_manager.cc b/gpu/command_buffer/service/program_manager.cc index ffa2f59..4b8dc7c 100644 --- a/gpu/command_buffer/service/program_manager.cc +++ b/gpu/command_buffer/service/program_manager.cc @@ -472,7 +472,7 @@ void ProgramManager::ForceCompileShader(const std::string* source, info->service_id(), max_len, &len, temp.get()); DCHECK(max_len == 0 || len < max_len); DCHECK(len == 0 || temp[len] == '\0'); - info->UpdateTranslatedSource(temp.get()); + info->UpdateTranslatedSource(max_len ? temp.get() : NULL); } GLint status = GL_FALSE; -- cgit v1.1