h264: er: Copy from the previous reference only if compatible