[MPlayer-cvslog] r19941 - trunk/libvo/vo_gl.c

reimar subversion at mplayerhq.hu
Fri Sep 22 22:13:21 CEST 2006


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++) {



More information about the MPlayer-cvslog mailing list