Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2014-06-10 15:10:37 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2014-06-10 15:10:37 +0400
commit74e32efbc8e292927db9b5e8118a63782ce96010 (patch)
treee57f38304d3b89d8a5dfc10df2f361e54606628f
parente8c63caf77a1d3470556433065261a4ede3ebae2 (diff)
Fix wrong memory write in partial render update with Save Buffers enabled
No idea why this issue hasn't been spotted before. Took several hours to figure out where exactly wrong memory access happens.. P.S. I really want to switch ImBuf->rect from int* to unsigned char*...
-rw-r--r--source/blender/imbuf/intern/colormanagement.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/imbuf/intern/colormanagement.c b/source/blender/imbuf/intern/colormanagement.c
index 21ee8ebe237..2644b8a278f 100644
--- a/source/blender/imbuf/intern/colormanagement.c
+++ b/source/blender/imbuf/intern/colormanagement.c
@@ -2809,7 +2809,7 @@ void IMB_partial_display_buffer_update(ImBuf *ibuf, const float *linear_buffer,
int y;
for (y = ymin; y < ymax; y++) {
int index = y * buffer_width * 4;
- memcpy(ibuf->rect + index, display_buffer + index, (xmax - xmin) * 4);
+ memcpy((unsigned char *)ibuf->rect + index, display_buffer + index, (xmax - xmin) * 4);
}
}
}