Not a bug. Buy offers have a person associated with them, but they are still tied to a region.
If you accept a Buy offer from a Lord who has since lost his position, I believe the former Lord who set it up will gain the gold, just like with any other offer.
The food will, of course, go to whatever region the person accepting the Buy offer is representing.
(If you accept a Sell order from a Lord who has since lost his position, the food still goes to his region.)