avcodec/motion_est: use 2x8x8 for interlaced qpel
Fixes out of array read Fixes Ticket4121 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
		
							parent
							
								
									928322c15f
								
							
						
					
					
						commit
						b50e003e1c
					
				@ -193,7 +193,13 @@ static av_always_inline int cmp_inline(MpegEncContext *s, const int x, const int
 | 
				
			|||||||
        int uvdxy;              /* no, it might not be used uninitialized */
 | 
					        int uvdxy;              /* no, it might not be used uninitialized */
 | 
				
			||||||
        if(dxy){
 | 
					        if(dxy){
 | 
				
			||||||
            if(qpel){
 | 
					            if(qpel){
 | 
				
			||||||
                c->qpel_put[size][dxy](c->temp, ref[0] + x + y*stride, stride); //FIXME prototype (add h)
 | 
					                if (h << size == 16) {
 | 
				
			||||||
 | 
					                    c->qpel_put[size][dxy](c->temp, ref[0] + x + y*stride, stride); //FIXME prototype (add h)
 | 
				
			||||||
 | 
					                } else if (size == 0 && h == 8) {
 | 
				
			||||||
 | 
					                    c->qpel_put[1][dxy](c->temp    , ref[0] + x + y*stride    , stride);
 | 
				
			||||||
 | 
					                    c->qpel_put[1][dxy](c->temp + 8, ref[0] + x + y*stride + 8, stride);
 | 
				
			||||||
 | 
					                } else
 | 
				
			||||||
 | 
					                    av_assert2(0);
 | 
				
			||||||
                if(chroma){
 | 
					                if(chroma){
 | 
				
			||||||
                    int cx= hx/2;
 | 
					                    int cx= hx/2;
 | 
				
			||||||
                    int cy= hy/2;
 | 
					                    int cy= hy/2;
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user