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
Just a note that rust strings can freely contain null bytes. `"foo\0bar"` is allowed in rust and will have a lenght of 7. So in rust adding a null byte you might still end up with a prefixed string.
Maybe instead of a null byte you could add something like 0b10111111? All rust strings are valid UTF-8 and a UTF-8 character can never begin with a 10 bit pattern as this the start pattern of a continuation byte. So for rust strings this would ensure that no byte slice derived from a string is a prefix of another.
Maybe instead of a null byte you could add something like
0b10111111
? All rust strings are valid UTF-8 and a UTF-8 character can never begin with a10
bit pattern as this the start pattern of a continuation byte. So for rust strings this would ensure that no byte slice derived from a string is a prefix of another.Originally posted by @DelSkayn in surrealdb/surrealkv#5 (comment)
The text was updated successfully, but these errors were encountered: