summaryrefslogtreecommitdiff
path: root/libavcodec/sunrast.c
diff options
context:
space:
mode:
authorAneesh Dogra <lionaneesh@gmail.com>2012-02-19 23:57:21 +0530
committerJustin Ruggles <justin.ruggles@gmail.com>2012-02-21 16:00:06 -0500
commit79c7064c5f48c974bc713471d2a0deac6bf873a3 (patch)
tree6bef8b8fb0457f9a25d9b1d143ef2fb0b8a55c9d /libavcodec/sunrast.c
parent70749c483c53312faa83ff3890fa4e2f7135453d (diff)
sunrast: Add a sample request for RMP_RAW colormap.
Signed-off-by: Justin Ruggles <justin.ruggles@gmail.com>
Diffstat (limited to 'libavcodec/sunrast.c')
-rw-r--r--libavcodec/sunrast.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/libavcodec/sunrast.c b/libavcodec/sunrast.c
index fef17b4054..b41bb2e930 100644
--- a/libavcodec/sunrast.c
+++ b/libavcodec/sunrast.c
@@ -77,7 +77,11 @@ static int sunrast_decode_frame(AVCodecContext *avctx, void *data,
av_log(avctx, AV_LOG_ERROR, "invalid image size\n");
return AVERROR_INVALIDDATA;
}
- if (maptype & ~1) {
+ if (maptype == RMT_RAW) {
+ av_log_ask_for_sample(avctx, "unsupported colormap type\n");
+ return AVERROR_PATCHWELCOME;
+ }
+ if (maptype > RMT_RAW) {
av_log(avctx, AV_LOG_ERROR, "invalid colormap type\n");
return AVERROR_INVALIDDATA;
}