summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorDuncan Lowther <Duncan.Lowther@glasgow.ac.uk>2023-06-14 15:29:39 +0100
committerDuncan Lowther <Duncan.Lowther@glasgow.ac.uk>2023-06-21 09:48:37 +0100
commitbc2ed8c55a69d80ea6aa8441673232a8c4054f13 (patch)
treec04d34d49fccb22c7563ef94dd061aa2a5221316
parentae778363702a759e987bb9209165f5a413dbd8a9 (diff)
downloadmicropython-bc2ed8c55a69d80ea6aa8441673232a8c4054f13.tar.gz
micropython-bc2ed8c55a69d80ea6aa8441673232a8c4054f13.zip
tests/extmod/uctypes_array_assign_le: Fix buffer.
Structure descriptor in test extmod/uctypes_array_assign_le is 6 bytes long, due to member "arr3" having length 4 (2 * UINT16) and offset 2, but only 5 bytes are allocated. Increased buffer length to 6 bytes. Signed-off-by: Duncan Lowther <Duncan.Lowther@glasgow.ac.uk>
-rw-r--r--tests/extmod/uctypes_array_assign_le.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/extmod/uctypes_array_assign_le.py b/tests/extmod/uctypes_array_assign_le.py
index d822faf7e8..b7fcdfb49c 100644
--- a/tests/extmod/uctypes_array_assign_le.py
+++ b/tests/extmod/uctypes_array_assign_le.py
@@ -18,7 +18,7 @@ desc = {
"arr8": (uctypes.ARRAY | 1, 1, {"l": uctypes.UINT32 | 0}),
}
-data = bytearray(5)
+data = bytearray(6)
S = uctypes.struct(uctypes.addressof(data), desc, uctypes.LITTLE_ENDIAN)