fix border==0,0 comparison