Commit 54692fcd authored by thakis@chromium.org's avatar thakis@chromium.org

clang/win: Fix calling delete[] on void* in base.

Calling delete[] on void* is undefined behavior. Cast to the right
type before calling delete[]. Fixes a clang warning.

BUG=82385
TBR=siggi

Review URL: https://codereview.chromium.org/401423002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284709 0039d316-1c4b-4281-b951-d872f2087c98
parent 60ffa235
...@@ -45,7 +45,7 @@ class TestConsumer: public EtwTraceConsumerBase<TestConsumer> { ...@@ -45,7 +45,7 @@ class TestConsumer: public EtwTraceConsumerBase<TestConsumer> {
void ClearQueue() { void ClearQueue() {
for (EventQueue::const_iterator it(events_.begin()), end(events_.end()); for (EventQueue::const_iterator it(events_.begin()), end(events_.end());
it != end; ++it) { it != end; ++it) {
delete[] it->MofData; delete[] reinterpret_cast<char*>(it->MofData);
} }
events_.clear(); events_.clear();
......
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