Fix T46605: Compositing causes access violation when rendering from command line

Seems was caused by the race condition in the stats printing, should be all fine now.

Nice for 'a' release.
This commit is contained in:
Sergey Sharybin 2015-10-27 21:03:22 +05:00
parent 7e7527d3ce
commit 242246e9fc
Notes: blender-bot 2023-02-14 08:29:56 +01:00
Referenced by issue #46605, Compositing causes access violation when rendering from command line
1 changed files with 4 additions and 3 deletions

View File

@ -2108,9 +2108,10 @@ static void ntree_render_scenes(Render *re)
/* bad call... need to think over proper method still */
static void render_composit_stats(void *UNUSED(arg), const char *str)
{
R.i.infostr = str;
R.stats_draw(R.sdh, &R.i);
R.i.infostr = NULL;
RenderStats i;
memcpy(&i, &R.i, sizeof(i));
i.infostr = str;
R.stats_draw(R.sdh, &i);
}
#ifdef WITH_FREESTYLE