cinepak: do not access arrays beyond allocated size