Fixed a bug when calculating face/line number from xi location

Tracker item: 3119