Mercurial > mplayer.hg
diff libswscale/colorspace-test.c @ 29542:3e7ffd70b12b
swscale: Check for return values of malloc.
author | ramiro |
---|---|
date | Sat, 29 Aug 2009 23:02:01 +0000 |
parents | c080f1f5c07e |
children | 0a999f052474 |
line wrap: on
line diff
--- a/libswscale/colorspace-test.c Sat Aug 29 03:36:09 2009 +0000 +++ b/libswscale/colorspace-test.c Sat Aug 29 23:02:01 2009 +0000 @@ -66,6 +66,9 @@ int failedNum=0; int passedNum=0; + if (!srcBuffer || !dstBuffer) + return -1; + av_log(NULL, AV_LOG_INFO, "memory corruption test ...\n"); args_parse(argc, argv); av_log(NULL, AV_LOG_INFO, "CPU capabilities forced to %x\n", cpu_caps);