Could you please add a printf("Pixel format = 0x%x\n", surface->format); in front of the g_assert_not_reached() in that function, and report which value is printed when you run it again?
Could you please add a not_reached( ) in that function, and report which value is printed when you run it again?
printf("Pixel format = 0x%x\n", surface->format);
in front of the g_assert_