From 88097e99099b8bea9c9e435d7c728afaa8bc24ff Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 25 Jul 2009 19:34:38 +0000 Subject: - BGE Python API converting a mesh from a python arg was broken but happened to work if the uninitialized pointer was not NULL. - iris.c - looks like a copy/paste error, was using rect where it could not have been initialized. --- source/blender/imbuf/intern/iris.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/blender/imbuf/intern') diff --git a/source/blender/imbuf/intern/iris.c b/source/blender/imbuf/intern/iris.c index eba148cb8a5..7b8c383ddb9 100644 --- a/source/blender/imbuf/intern/iris.c +++ b/source/blender/imbuf/intern/iris.c @@ -245,7 +245,6 @@ struct ImBuf *imb_loadiris(unsigned char *mem, int flags) int xsize, ysize, zsize; int bpp, rle, cur, badorder; ImBuf * ibuf; - uchar * rect; /*printf("new iris\n");*/ @@ -436,6 +435,7 @@ struct ImBuf *imb_loadiris(unsigned char *mem, int flags) if (bpp == 1) { + uchar * rect; if (image.zsize == 1){ rect = (uchar *) ibuf->rect; @@ -467,7 +467,7 @@ struct ImBuf *imb_loadiris(unsigned char *mem, int flags) fbase = ibuf->rect_float; for (x = ibuf->x * ibuf->y; x > 0; x--) { fbase[0] = 1; - fbase[1] = rect[2] = rect[3]; + fbase[1] = fbase[2] = fbase[3]; fbase += 4; } } else if (image.zsize == 2){ -- cgit v1.2.3