diff options
author | bajones@chromium.org <bajones@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-06-14 01:04:09 +0000 |
---|---|---|
committer | bajones@chromium.org <bajones@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-06-14 01:04:09 +0000 |
commit | f16cc9fe55e2ae5114cbbaaa013ac1e83a263446 (patch) | |
tree | 30bc4f95ea3dcb4c6f27d09831dd2f52d4d40810 | |
parent | e014b8fe9d12e1d79c46dd7a88eb93d03cf0ff8f (diff) | |
download | chromium_src-f16cc9fe55e2ae5114cbbaaa013ac1e83a263446.zip chromium_src-f16cc9fe55e2ae5114cbbaaa013ac1e83a263446.tar.gz chromium_src-f16cc9fe55e2ae5114cbbaaa013ac1e83a263446.tar.bz2 |
Fixed logic error in string replace that was truncating extension string inadvertantly
BUG=
Review URL: https://chromiumcodereview.appspot.com/16870005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@206261 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | gpu/command_buffer/service/gles2_cmd_decoder.cc | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/gpu/command_buffer/service/gles2_cmd_decoder.cc b/gpu/command_buffer/service/gles2_cmd_decoder.cc index 41d7c6d..a8562ad 100644 --- a/gpu/command_buffer/service/gles2_cmd_decoder.cc +++ b/gpu/command_buffer/service/gles2_cmd_decoder.cc @@ -7106,24 +7106,21 @@ error::Error GLES2DecoderImpl::HandleGetString( if (!derivatives_explicitly_enabled_) { size_t offset = extensions.find(kOESDerivativeExtension); if (std::string::npos != offset) { - extensions.replace(offset, - offset + arraysize(kOESDerivativeExtension), + extensions.replace(offset, arraysize(kOESDerivativeExtension), std::string()); } } if (!frag_depth_explicitly_enabled_) { size_t offset = extensions.find(kEXTFragDepthExtension); if (std::string::npos != offset) { - extensions.replace(offset, - offset + arraysize(kEXTFragDepthExtension), + extensions.replace(offset, arraysize(kEXTFragDepthExtension), std::string()); } } if (!draw_buffers_explicitly_enabled_) { size_t offset = extensions.find(kEXTDrawBuffersExtension); if (std::string::npos != offset) { - extensions.replace(offset, - offset + arraysize(kEXTDrawBuffersExtension), + extensions.replace(offset, arraysize(kEXTDrawBuffersExtension), std::string()); } } |