1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
|
Index: h5py/h5py/_conv.templ.pyx
===================================================================
--- h5py.orig/h5py/_conv.templ.pyx 2025-10-27 21:10:24.821297659 +0100
+++ h5py/h5py/_conv.templ.pyx 2025-10-27 21:31:58.423581668 +0100
@@ -704,9 +704,10 @@
vlen_t in_vlen0
size_t size, itemsize
- #Replaces the memcpy
- size = in_vlen0.len = in_vlen[0].len
- data = in_vlen0.ptr = in_vlen[0].ptr
+ memcpy(&size, &in_vlen[0].len, sizeof(size_t))
+ memcpy(&data, &in_vlen[0].ptr, sizeof(void*))
+ in_vlen0.len = size
+ in_vlen0.ptr = data
dims[0] = size
itemsize = H5Tget_size(outtype.id)
@@ -871,8 +872,8 @@
H5Tconvert(intype.id, outtype.id, len, data, back_buf, H5P_DEFAULT)
- in_vlen[0].len = len
- in_vlen[0].ptr = data
+ memcpy(&in_vlen[0].len, &len, sizeof(size_t))
+ memcpy(&in_vlen[0].ptr, &data, sizeof(void*))
finally:
free(back_buf)
|