22 Sep
2006
22 Sep
'06
4:13 p.m.
Author: reimar Date: Fri Sep 22 22:13:21 2006 New Revision: 19941 Modified: trunk/libvo/vo_gl.c Log: Make genEOSD behaviour with NULL data more explicit Modified: trunk/libvo/vo_gl.c ============================================================================== --- trunk/libvo/vo_gl.c (original) +++ trunk/libvo/vo_gl.c Fri Sep 22 22:13:21 2006 @@ -251,10 +251,10 @@ GLint scale_type = (scaled_osd) ? GL_LINEAR : GL_NEAREST; ass_image_t *i; clearEOSD(); + if (!img) + return; for (i = img; i; i = i->next) eosdtexCnt++; - if (!eosdtexCnt) - return; eosdtex = calloc(eosdtexCnt, sizeof(GLuint)); glGenTextures(eosdtexCnt, eosdtex); for (i = img, curtex = eosdtex; i; i = i->next, curtex++) {