Revision 0fb669ae

View differences:

libavcodec/interplayvideo.c
77 77
} IpvideoContext;
78 78

  
79 79
#define CHECK_STREAM_PTR(n) \
80
  if (s->stream_end - s->stream_ptr < n) { \
81
    av_log(s->avctx, AV_LOG_ERROR, "Interplay video warning: stream_ptr out of bounds (%p >= %p)\n", \
82
      s->stream_ptr + n, s->stream_end); \
83
    return -1; \
84
  }
80
    if (s->stream_end - s->stream_ptr < n) { \
81
        av_log(s->avctx, AV_LOG_ERROR, "Interplay video warning: stream_ptr out of bounds (%p >= %p)\n", \
82
               s->stream_ptr + n, s->stream_end); \
83
        return -1; \
84
    }
85 85

  
86 86
static int copy_from(IpvideoContext *s, AVFrame *src, int delta_x, int delta_y)
87 87
{
......
591 591
            opcode = get_bits(&gb, 4);
592 592

  
593 593
            debug_interplay("  block @ (%3d, %3d): encoding 0x%X, data ptr @ %p\n",
594
                x - y, y / s->stride, opcode, s->stream_ptr);
594
                            x - y, y / s->stride, opcode, s->stream_ptr);
595 595

  
596 596
            s->pixel_ptr = s->current_frame.data[0] + x;
597 597
            ret = ipvideo_decode_block[opcode](s);
598 598
            if (ret != 0) {
599 599
                av_log(s->avctx, AV_LOG_ERROR, " Interplay video: decode problem on frame %d, @ block (%d, %d)\n",
600
                    frame, x - y, y / s->stride);
600
                       frame, x - y, y / s->stride);
601 601
                return;
602 602
            }
603 603
        }
604 604
    }
605 605
    if (s->stream_end - s->stream_ptr > 1) {
606 606
        av_log(s->avctx, AV_LOG_ERROR, " Interplay video: decode finished with %td bytes left over\n",
607
            s->stream_end - s->stream_ptr);
607
               s->stream_end - s->stream_ptr);
608 608
    }
609 609
}
610 610

  

Also available in: Unified diff