R' Huna says that if one is forced into selling something and receives money for it, the sale is binding. The gemara explains the rationale is that everyone who sells items that are dear to them only does so under pressure and financial difficulty, yet the sale is binding, so this type of force is no different. To that the gemara responds - ודלמא שאני אונסא דנפשיה מאונסא דאחריני, meaning that there is a difference between a self imposed o'nes and an external o'nes. When one is forced to do financial pressures, he is making a decision under the circumstances. Although he would prefer to never be in such a predicament, nevertheless he is making a conscious decision under the circumstances - this decision is regarded as ratzon. But if one is being coerced or forced by someone else, we don't consider his decision to be b'ratzon so it is possible that the sale isn't binding (which is the opinion of Rav Bibi, unlike R' Huna who holds that so long as he receives something in return, it is binding).
This concept if very important to distinguish between what we can call an internal o'nes and an external o'nes. This issue arises in two places, but the distinction is exactly the same.
1. The Rambam in yesodei hatorah (perek 5) holds that if one's life is being threatened unless he serves avoda zara he is obligated to forfeit his life. But if he doesn't do so, he is still considered an o'nes and not killed for serving avoda zarah. Yet, the Rambam writes (halacha 6) that if one is deathly ill and uses avoda zara means to heal himself, he is chayev whatever punishment is normally associated with the act that he committed. Why is it considered o'nes when he is forced by others, but not when he is ill? The Ohr Samei'ach makes the distinction that is hinted to in our gemara (but doesn't mention the gemara). Based on our gemara the distinction is clear. When someone else is threatening to kill him, the decision that he makes is not considered "ratzon", because he doesn't at all want to do what he is being forced to do. But when he is ill and uses avoda zara to save his life, he is deciding to benefit from avoda zara. Surely, he is faced with extenuating circumstances, but that doesn't change the fact that he is making a conscious decision and is therefore liable for it.
2. The Rama writes in Hilchos Brachos (204:8) that if one is being forced to eat non-kosher food, even though he is enjoying the taste he doesn't make a bracha since he is considered an o'nes. But the Shulchan Aruch writes in the very next halacha that one who eats non-kosher because they are ill and they need it for medicinal purposes, makes a bracha on the food. The Taz (12) struggles with this and elaborates about it (siman 196:1). But based on our gemara the distinction is simple. One who is being forced to eat non-kosher by someone else is not making a decision to eat non-kosher, and would not eat it if not for being forced at gun point. Therefore, we don't consider this eating b'raztzon, and it is not worthy of a bracha. But, one who is ill, although he has severe circumstances, he is making a decision to eat the non-kosher food under the circumstances (and being that his life is threatened it is permitted for him to eat it), so we consider this to be a decision made b'ratzon and worthy of a bracha.