summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel Freitas <miguelfreitas@users.sourceforge.net>2001-11-20 03:43:18 +0000
committerMiguel Freitas <miguelfreitas@users.sourceforge.net>2001-11-20 03:43:18 +0000
commit3caeb00e32368497418444d92f3748073fa69a08 (patch)
tree2b7cb09e4ea4af03051a167ecfb605b50ef7f4cd
parent4d918ed31b1d88faf30a9003bdea697cf197abb7 (diff)
downloadxine-lib-3caeb00e32368497418444d92f3748073fa69a08.tar.gz
xine-lib-3caeb00e32368497418444d92f3748073fa69a08.tar.bz2
avoid segfault if rle is null
CVS patchset: 1085 CVS date: 2001/11/20 03:43:18
-rw-r--r--src/libspudec/spu.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/libspudec/spu.c b/src/libspudec/spu.c
index dcee56c55..62e89ef90 100644
--- a/src/libspudec/spu.c
+++ b/src/libspudec/spu.c
@@ -35,7 +35,7 @@
* along with this program; see the file COPYING. If not, write to
* the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
*
- * $Id: spu.c,v 1.23 2001/11/18 03:53:24 guenter Exp $
+ * $Id: spu.c,v 1.24 2001/11/20 03:43:18 miguelfreitas Exp $
*
*/
@@ -452,6 +452,11 @@ void spu_discover_clut(spu_state_t *state, vo_overlay_t *ovl)
memset(found,0,sizeof(found));
rle = ovl->rle;
+ /* this seems to be a problem somewhere else,
+ why rle is null? */
+ if( !rle )
+ return;
+
/* suppose the first and last pixels are bg */
if( rle[0].color != rle[ovl->num_rle-1].color )
return;