Comment 5 for bug 962664

Revision history for this message
Bryce Harrington (bryce) wrote :

        for ( int i = 0; i <= 150; i++ )
        {
            y = i * cos(teta) + 20;
            x = i * sin(teta) + start_x + 240 * j;
            *(p_picture->p[0].p_pixels +
                    (p_picture->p[0].i_lines - y - 1 ) * p_picture->p[0].i_pitch
                    + x ) = 0xAD;
            *(p_picture->p[1].p_pixels +
                    (p_picture->p[1].i_lines - y / 2 - 1 ) * p_picture->p[1].i_pitch
                    + x / 2 ) = 0xFC;
            *(p_picture->p[2].p_pixels +
                    (p_picture->p[2].i_lines - y / 2 - 1 ) * p_picture->p[2].i_pitch
                    + x / 2 ) = 0xAC; /* <-- crashes here */
        }

Unfortunately most of the variables are optimized out of the backtrace, but presumably the calculated pointer value there is incorrect.

This crash was reported against 2.0.0, but the effects.c code file has not changed in Precise's 2.0.1, and is the same with current upstream head.

Are you able to reproduce this bug easily? If so, can you describe the steps needed to reproduce it?