Files
sdk/runtime/tests
Kevin Millikin b38c00a341 Avoid triggering an ASSERT in TypedData
When a zero-sized string occurs as that last string in the Kernel
string table, the code would attempt to compute the address that lies
one element past the end of the string table's backing store.  Though
this is benign in C++ as long as that address is not dereferenced, it
would trigger an assertion failure in TypedData::DataAddr.

Avoid triggering the assertion by performing the address arithmetic in
the caller based on DataAddr(0) rather than relying on the address
arithmetic in DataAddr.

This fixes issue 30420.

BUG=https://github.com/dart-lang/sdk/issues/30420
R=aam@google.com, asiva@google.com

Review-Url: https://codereview.chromium.org/3003023002 .
2017-08-22 09:27:24 +02:00
..