if x1=x2, then you would have a vertical line crossing the specifed x1 or x2 (any one will do since they are the same). the equation of the line would be x=x1 or x=x2 .
in addition if you had y1=y2, the line would be horizontal. hence its equation would just be y=y1 or y2.