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>2013-01-28 16:57:56 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2013-01-28 16:57:56 +0400
commit2a144f03048efb0caaf29049f7a6e518148e3fb2 (patch)
treef3c0ab3863a2bc3494f6dd2b807dcc8d4177f444 /source/blender/editors/interface/interface_icons.c
parent2bae448ed554a27377baa3c4e78c88623597c880 (diff)
Fix for wrong icons buffer initialization happens for cards
without NPOT support. Was wrong stride used for memcpy leading to wrong memory writes in def_internal_icon. It's a regression since matcap commit. Should fix the following reports: - #33993: Crash on Blender startup (Vista x32) - #33996: Latest build crashes on win xp
Diffstat (limited to 'source/blender/editors/interface/interface_icons.c')
-rw-r--r--source/blender/editors/interface/interface_icons.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/interface/interface_icons.c b/source/blender/editors/interface/interface_icons.c
index 8b4b1752774..619fb18cd7a 100644
--- a/source/blender/editors/interface/interface_icons.c
+++ b/source/blender/editors/interface/interface_icons.c
@@ -169,7 +169,7 @@ static DrawInfo *def_internal_icon(ImBuf *bbuf, int icon_id, int xofs, int yofs,
/* this code assumes square images */
imgsize = bbuf->x;
for (y = 0; y < size; y++) {
- memcpy(&iimg->rect[y * size], &bbuf->rect[(y + yofs) * imgsize + xofs], imgsize * sizeof(int));
+ memcpy(&iimg->rect[y * size], &bbuf->rect[(y + yofs) * imgsize + xofs], size * sizeof(int));
}
}
}