diff options
author | Ivan Dlugos <6349682+vaind@users.noreply.github.com> | 2021-01-07 20:40:47 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-07 11:40:47 -0800 |
commit | 08d2ce844b1f03fda0a22d911f90943c5984b662 (patch) | |
tree | 88225acc60634e1cafed11614b507772fed98264 /dart | |
parent | a15a8d930d894a0eca240f870bea1cc0674fcc42 (diff) | |
download | flatbuffers-08d2ce844b1f03fda0a22d911f90943c5984b662.tar.gz flatbuffers-08d2ce844b1f03fda0a22d911f90943c5984b662.tar.bz2 flatbuffers-08d2ce844b1f03fda0a22d911f90943c5984b662.zip |
fix Dart Builder._writeString() - always write trailing zero byte (#6390)
Diffstat (limited to 'dart')
-rw-r--r-- | dart/lib/flat_buffers.dart | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/dart/lib/flat_buffers.dart b/dart/lib/flat_buffers.dart index 0f4ccbcc..99fd6a2d 100644 --- a/dart/lib/flat_buffers.dart +++ b/dart/lib/flat_buffers.dart @@ -670,6 +670,7 @@ class Builder { for (int i = 0; i < length; i++) { _buf.setUint8(offset++, bytes[i]); } + _buf.setUint8(offset, 0); // trailing zero return result; } |