Paul effectively answers this question of the meaning of "unwholesome talk", or, "corrupting talk", ESV, (Eph 4:29) a few verses later:
Eph 4:31 - Get rid of all bitterness, rage and anger, outcry and
slander, along with every form of malice.
Eph 5:4 - Nor should there be obscenity, foolish talk, or crude
joking, which are out of character, but rather thanksgiving.
Eph 5:6 - Let no one deceive you with empty words, for because of such
things the wrath of God is coming on the sons of disobedience.
Benson comments on Eph 4:29 as follows:
The original expression, λογος σαπρος, is literally, rotten or putrid
speech; that is, speech offensive to the hearers, or calculated to
infect them with sin; and is in direct opposition to that which is
seasoned with salt, and is recommended (Colossians 4:6) as tending to
preserve persons from corruption. The apostle does not merely include
in this expression obscene discourse of every kind, but also all
flattery, calumny, railing, boasting, tale-bearing, backbiting,
commendations of vice and impiety, profane jestings on religion, its
ministers and professors, trifling conversation; and, indeed, all
discourse that is not either about necessary business, or, as the next
clause expresses it, is not good to the use of edifying — Calculated
to instruct, direct, reprove, encourage, excite to duty, comfort, or
in some way edify and minister grace to the hearers.