Bug 246267
| Summary: | [WTF] ASSERT on source pointer before calling memcpy() | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Philippe Normand <philn> |
| Component: | Web Template Framework | Assignee: | Philippe Normand <philn> |
| Status: | RESOLVED DUPLICATE | ||
| Severity: | Normal | CC: | darin |
| Priority: | P2 | ||
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
Philippe Normand
As noted in https://bugs.webkit.org/show_bug.cgi?id=245640 in at least one case memcpy() was being called with a null source pointer in StringImpl::copyCharacters(). We should add an ASSERT there.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Philippe Normand
Pull request: https://github.com/WebKit/WebKit/pull/5180
Philippe Normand
*** This bug has been marked as a duplicate of bug 246260 ***
Darin Adler
Turns out *many* callers are passing nullptr for destination pointer as well as source pointer, so the use of memcpy there is incorrect. I ended up working on a much bigger patch for this, but in the end we might want to land something smaller than what I did.