Re: [Mesa-dev] [PATCH 3/3] mesa/swrast: Move memory allocation outside the blit loop

2013-04-16 Thread Ian Romanick
On 04/15/2013 11:05 PM, Kenneth Graunke wrote: On 04/15/2013 05:53 PM, Ian Romanick wrote: From: Ian Romanick Assume the maximum pixel size (16 bytes per pixel). In addition to moving redundant malloc and free calls outside the loop, this fixes a potential resource leak when a surface is mapp

Re: [Mesa-dev] [PATCH 3/3] mesa/swrast: Move memory allocation outside the blit loop

2013-04-15 Thread Kenneth Graunke
On 04/15/2013 05:53 PM, Ian Romanick wrote: From: Ian Romanick Assume the maximum pixel size (16 bytes per pixel). In addition to moving redundant malloc and free calls outside the loop, this fixes a potential resource leak when a surface is mapped and the malloc fails. This also makes blit_ne

[Mesa-dev] [PATCH 3/3] mesa/swrast: Move memory allocation outside the blit loop

2013-04-15 Thread Ian Romanick
From: Ian Romanick Assume the maximum pixel size (16 bytes per pixel). In addition to moving redundant malloc and free calls outside the loop, this fixes a potential resource leak when a surface is mapped and the malloc fails. This also makes blit_nearest look a bit more like blit_linear. Signe