Science Fiction god Robert Heinlien called this problem "Bread and Circuses" - a reference to Roman Emperors providing food and entertainment to distract the masses. In "To Sail Beyond The Sunset" the character Lazarus Long discusses this problem:
"A perfect democracy, a 'warm body' democracy in which every adult may vote and all votes count equally has no internal feedback for self correction. It depends solely on the wisdom and self-restraint of citizens...which is opposed by the folly and lack of self-restraint of other citizens. What is supposed to happen in a democracy is that each sovereign citizen will always vote in the public interest for the safety and welfare of all. But what does happen is that he votes his own self-interest as he sees it...which for the majority translates as 'Bread and Circuses'
"Bread and Circuses is the cancer of democracy, the fatal disease for which there is no cure. Democracy often works beautifully at first. But once a state extends the franchise to every warm body, be he producer or parasite, that day marks the beginning of the end of the state. For when the plebs discover that they can vote themselves bread and circuses without limit and that the productive members of the body politic cannot stop them, they will do so, until the state bleeds to death, or in its weakened condition the state succumbs to an invader--the barbarians enter Rome."