The Chofetz Chaim dedicates an entire chapter (klal 3) to discuss the various interpretations of Rabab Bar Rav Huna who says - כל מילתא דמתאמרא באפי תלתא לית בה משום לישנא בישא
Rashbam understands that he is discussing a case where Reuven violated the issur of loshon horah by saying something negative in the presence of 3 people about Shimon. It would then be permitted for these people to repeat to Shimon what Reuven said about them, since it was said in the presence of 3, it is assumed that Shimon will find out anyway. The difficulty with this approach is that it seems somewhat circular - the 3 people are allowed to repeat the rechilus to shimon because they will repeat the rechilus to him anyway so he is bound to find out. Therefore, the chofetz chaim writes (2:5) that if one of the 3 is a yarei Hashem and is not likely to repeat the loshon horah by saying rechilus to shimon, it would be forbidden for any of the 3 to repeat it because it is as if it wasn't said in the presence of 3. The Rambam seems to take a similar approach but rather than explaining it based on rechilus he simply says that the 3 people who heard the loshon horah are permitted to repeat it to others since they are bound to find out anyway. But the Rambam stipulates that when one of the 3 repeat over the loshon hora, they cannot intend to degrade the person they are speaking about or make it more revealed (for example, if it a local group knew about it, it would be forbidden to publish in the papers for the purpose of spreading the news to others).
Tosafos has an entirely different approach where he completely avoids the heter of the rashbam and rambam. The gemara is speaking of an avak loshon hora which can be interpreted both for good and for bad. The idea of telling it over in front of 3 people is a litmus test whether it is actually loshon horah. If the teller is not embarrassed to say it over in front of 3 people which will likely lead to the one being spoken about hearing that he was spoken about, it is not loshon hora. But if the speaker would be afraid to tell it over to 3 people out of fear that the person being spoken about will find out, it is loshon horah (the chofetz chaim proves that tosafos cannot be matir outright loshon hora even if told to 3).
Rabbeinu Yona (shaarei teshuva 228) has an alternate approach where he explains the case to be when the loshon horah is being spoken about a person who there isn't any real issur to speak about - see there.
According to all the approaches, the connection to macha'ah is very simply that we find by loshon horah an assumption that word travels when told in the presence of 3, therefore a macha'ah must be done in the presence of 3. But, as the Rashbam points out there is no violation of loshon horah at all to spread a macha'ah because it is being done for a constructive purpose, so that the machzik holds on to his contract to prove that the field belongs to him.