John Gill's Exposition of the Whole Bible
Ecclesiastes 7:21
Also take no heed unto all words that are spoken,.... Seeing so it is, that imperfection attends the best of men, no man is wise at all times, foolish words and unguarded expressions will sometimes drop from him, which it is better to take no notice of; they should not be strictly attended to, and closely examined, since they will not bear it. A man should not listen to everything that is said of himself or others; he should not curiously inquire what men say of him; and what he himself hears he should take no notice of; it is often best to let it pass, and not call it over again; to feign the hearing of a thing, or make as if you did not hear it; for oftentimes, by rehearsing a matter, or taking up words spoken, a deal of trouble and mischief follows; a man should not "give [his] heart" f to it, as it is in the Hebrew text; he should not give his mind to what is said of him, but be careless and indifferent about it; much less should he lay it up in his mind, and meditate revenge for it. The Targum, Septuagint, Syriac, and Arabic versions, restrain it to words spoken by wicked men, whose tongues are their own, and will say what they please; among these may be ranked, more especially, detractors, whisperers, backbiters, and talebearers, who should not be listened unto and encouraged; though there is no necessity of thus limiting the sense, which is more general, and may include what is said by any man, even good men, since they have their infirmities; it seems chiefly to have respect to defamatory words, by what follows;
lest thou hear thy servant curse thee; speak slightly, scoffingly, and reproachfully of thee, as Shimei of David; which must be very disagreeable and vexatious to hear from one so mean and abject, and who is dependent on him, earns his bread of him, and gets his livelihood in his service; and to whom, perhaps, he has been kind, and so is guilty of base ingratitude, which aggravates the more; or, if not, if what he says is just, to hear it must give great uneasiness.
f אל תתן לבך "ne des tuum cor", Montanus.