In a crazy coincidence, we spent the next night in a different hotel in a different city and the same thing happened again.
I was surprised by this. I had assumed that the system that tracks reservations, available rooms, etc, would somehow be connected to the system that reprograms the magnetic stripe keys. I thought it would be harder for the front desk to hand out a second set of keys without some kind of warning message ("Hey, you already checked someone into that room ... are you sure you want to give out 3 more keys to the SAME ROOM?"). Apparently I've overestimated the room key/reservation systems in place at most hotels (another commenter here mentioned using DOS for reservations?!).
So, does UPM solve this problem? :)