Commit e1de1ab3 by Geoff Lang Committed by Commit Bot

D3D: Store error message by std::string instead of const char*.

These error strings are stored for recording later we can't depend on them still being alive so make a copy. BUG=962439 Change-Id: Ie9156c99b9ce79df4a11087bdcab92d980e959a4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1610078Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
parent f1e3609c
......@@ -531,7 +531,8 @@ class ProgramD3D::GetExecutableTask : public Closure, public d3d::Context
void popError(d3d::Context *context)
{
context->handleResult(mStoredHR, mStoredMessage, mStoredFile, mStoredFunction, mStoredLine);
context->handleResult(mStoredHR, mStoredMessage.c_str(), mStoredFile, mStoredFunction,
mStoredLine);
}
protected:
......@@ -540,7 +541,7 @@ class ProgramD3D::GetExecutableTask : public Closure, public d3d::Context
gl::InfoLog mInfoLog;
ShaderExecutableD3D *mExecutable = nullptr;
HRESULT mStoredHR = S_OK;
const char *mStoredMessage = nullptr;
std::string mStoredMessage;
const char *mStoredFile = nullptr;
const char *mStoredFunction = nullptr;
unsigned int mStoredLine = 0;
......
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