You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When `_alloc` is equal to `_size`, the `is_null_terminated` method will
point to arbitrary memory when checking for the `0` byte. This PR makes
that method first check that `_alloc != _size` before reading the
`_size` byte of the `Pointer[U8]`.
Fixes#1425
The current implementation of
String.is_null_terminated
is:This would seem to point into arbitrary memory when
_alloc
and_size
are the same (in other words, when the String is not null terminated).The text was updated successfully, but these errors were encountered: