Mass Effect 2 is sort of just weird like that. You could have maxed paragon or renegade bars without getting the morality dialogue, because it calculates your morality by how many points you've earned out of how many could be earned, unlike Mass Effect 1 where it was whatever you had more of (which was way better, in my opinion). The same thing happened to me in that fight, only it could've been expected since both my bars were at about half since I'm neutral. But I think you should've sided with Tali, because once you get back your morality dialogue later, it is much easier to get back Legion's loyalty. Maybe go back to a save if there is one. Hope this helped! It's not a glitch though, just tough luck.