---
libavcodec/h264_slice.c | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c
index 8d79740..87d6582 100644
--- a/libavcodec/h264_slice.c
+++ b/libavcodec/h264_slice.c
@@ -286,8 +286,6 @@ static int initialize_cur_frame(H264Context *h)
return 0;
}
-#define IN_RANGE(a, b, size) (((a) >= (b)) && ((a) < ((b) + (size))))
-
#define REBASE_PICTURE(pic, new_ctx, old_ctx) \
((pic && pic >= old_ctx->DPB && \
pic < old_ctx->DPB + H264_MAX_PICTURE_COUNT) ? \
@@ -298,14 +296,8 @@ static void copy_picture_range(H264Picture **to,
H264Picture **from, int count,
H264Context *old_base)
{
int i;
-
- for (i = 0; i < count; i++) {
- assert((IN_RANGE(from[i], old_base, sizeof(*old_base)) ||
- IN_RANGE(from[i], old_base->DPB,
- sizeof(H264Picture) * H264_MAX_PICTURE_COUNT) ||
- !from[i]));
+ for (i = 0; i < count; i++)
to[i] = REBASE_PICTURE(from[i], new_base, old_base);
- }
}
static int h264_slice_header_init(H264Context *h);
--
2.1.4
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel