patch [#23537] Memory leak in compositor rotate node

from Jeroen Bakker (jbakker)
This commit is contained in:
Campbell Barton
2010-08-27 22:09:24 +00:00
parent cc70bffb62
commit b76176faff

View File

@@ -71,7 +71,7 @@ static void node_composit_exec_rotate(void *data, bNode *node, bNodeStack **in,
ibuf=IMB_allocImBuf(cbuf->x, cbuf->y, 32, 0, 0);
obuf=IMB_allocImBuf(stackbuf->x, stackbuf->y, 32, 0, 0);
if(ibuf){
if(ibuf && obuf){
ibuf->rect_float=cbuf->rect;
obuf->rect_float=stackbuf->rect;
@@ -103,6 +103,9 @@ static void node_composit_exec_rotate(void *data, bNode *node, bNodeStack **in,
centx= (float)cbuf->xof; centy= (float)cbuf->yof;
stackbuf->xof= (int)( c*centx + s*centy);
stackbuf->yof= (int)(-s*centx + c*centy);
IMB_freeImBuf(ibuf);
IMB_freeImBuf(obuf);
}
/* pass on output and free */