If you absolutely cannot ever sell any lenses, and you will never use a backup body (i.e. keep your 50D and 17-55), then buying the 17-55 would be a mistake, because after you upgrade it will sit in the closet. On the other hand, if you are open to the idea of selling your lens (most often within 20% of what you paid for it), or cna utilize a second body in the future, then it would be far wiser to buy the 17-55.

That said, they're really not comparable at all. The closest thing to a "full frame compatible" 17-55 is the 16-35 f/2.8 or 17-40 f/4. The 24-70 is just a completely different field of view.

The 17-55 on 50D is equivalent to a 28-90 f/4.5 on full frame.
The 24-70 on 50D is equivalent to a 38-110 f/4.5 on full frame.
Going from 28mm to 38mm is very different. And going from 38mm to 24mm is even more different.