Files
test2/source/blender
Jacques Lucke 9d87291c40 Fix #129691: heap buffer overflow when writing unaligned data to .blend file
`writedata` used to align the written buffer size to a multiple of 4. This
causes multiple issues:
* Writes uninitialized data.
* Crash with ASAN due to a heap buffer overflow if the buffer is not any longer
  than what is passed in.
* Modifies the length of the buffer which can't be undone when reading the
  buffer again.

I don't know of any reason for this alignment here. I'd think that it doesn't
matter when writing to a file. If it would matter, then we should probably align
to at least 8 nowadays because that's the alignment of pointers. The original
reason for this alignment seems to be lost to history. It was already part of
the initial commit.

Pull Request: https://projects.blender.org/blender/blender/pulls/129821
2024-11-05 15:51:37 +01:00
..
2024-10-04 12:20:33 +02:00
2024-10-31 21:56:52 +11:00
2024-09-20 13:14:57 +10:00
2024-10-04 11:33:21 +02:00
2024-11-05 15:08:15 +01:00
2024-10-23 13:14:37 +11:00
2024-11-02 17:34:00 +11:00
2024-11-05 23:05:43 +11:00
2024-11-05 12:06:47 +01:00
2024-10-04 11:33:21 +02:00