Ported r2809 from ZXing
Ported r2809 from ZXing

Original commit message: "Avoid AIOOBE, again, with over large
correction for nudge in corner cases"

jianwoo/ZXingObjC,YotrolZ/ZXingObjC,fuzhiqiang1989/ZXingObjC,TheLevelUp/ZXingObjC,davidjackman/ZXingObjC,RockyAo/ZXingObjC,Kevin775263419/ZXingObjC,JeremyPacker/ZXingObjC,ufs-slizhik/ZXingObjC,xuxubin/ZXingObjC,fanwenkai/ZXingObjC,sdhzwm/ZXingObjC,adan016/ZXingObjC,YotrolZ/ZXingObjC,benjohnde/ZXingObjC,davidjackman/ZXingObjC,rowliny/ZXingObjC,sdhzwm/ZXingObjC,zeffon/ZXingObjC,wuxsoft/ZXingObjC,zilaiyedaren/ZXingObjC,tejesh-alimilli/ZXingObjC,Kalvar/ZXingObjC,wuxsoft/ZXingObjC,cortices/ZXingObjC,zilaiyedaren/ZXingObjC,jebai0521/ZXingObjC,adan016/ZXingObjC,rkpant/ZXingObjC,TheLevelUp/ZXingObjC,JeremyPacker/ZXingObjC,fuzhiqiang1989/ZXingObjC,tejesh-alimilli/ZXingObjC,Kalvar/ZXingObjC,peacemoon/ZXingObjC,rkpant/ZXingObjC,Stocard/ZXingObjC,Kevin775263419/ZXingObjC,jianwoo/ZXingObjC,jebai0521/ZXingObjC,Stocard/ZXingObjC,elegion/ios-pods-ZXingObjC,fanwenkai/ZXingObjC,RockyAo/ZXingObjC,ufs-slizhik/ZXingObjC,trsathya/ZXingObjC,elegion/ios-pods-ZXingObjC,peacemoon/ZXingObjC,benjohnde/ZXingObjC,cortices/ZXingObjC,trsathya/ZXingObjC,zeffon/ZXingObjC,rowliny/ZXingObjC,xuxubin/ZXingObjC