When an offense is committed on the boundary of two or more counties or within a quarter of a mile thereof or when it is committed so near the boundary of two counties as to render it doubtful in which the offense was committed, venue is in either county.