# HG changeset patch # User reimar # Date 1158956001 0 # Node ID 698b1d68ac83de6f830f504bb94b922e54fc5b24 # Parent 864dcc4f040826e4487c3d24effe62ae660ca42b Make genEOSD behaviour with NULL data more explicit diff -r 864dcc4f0408 -r 698b1d68ac83 libvo/vo_gl.c --- a/libvo/vo_gl.c Fri Sep 22 19:58:43 2006 +0000 +++ b/libvo/vo_gl.c Fri Sep 22 20:13:21 2006 +0000 @@ -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++) {