As soon as I read your description, I remembered reading that story many years ago in an anthology. I also remembered that the poison pill provided by the government to all adult citizens was called "the Sooey" or "the Sooey Pill." ("Sooey" for "Suicide," of course.)
A little Googling then told me that "The Sooey Pill" was also the title of the story! Written by Elaine Slater. First published in Ellery Queen's Mystery Magazine (June, 1969).
The way I remember it, the story was presented as a murder mystery, with the main viewpoint character being a police detective who was trying to figure out who would want to murder a cute little boy by feeding him a Sooey. After checking out everyone who'd been within a mile of the crime scene who had ever previously reported "losing" a Sooey and needing a replacement (but theoretically might have been secretly saving the old one for a future murder), the detective finally asked the kid's own parents to each show him their standard-issue Sooey Pills. The father immediately produced his, but the mother went to pieces. She had regarded this as a mercy killing for her beloved son, so that he wouldn't grow up to be increasingly discouraged and depressed by the ugly world around him. The punishment for her was as you described from memory.
Some more Googling tells me that the story was reprinted in an anthology titled 100 Malicious Little Mysteries (with Martin H. Greenberg, Isaac Asimov, and Joseph D. Olander having collaborated in selecting the short stories to be reprinted therein). I must have read it there; I own a copy. It looks like you ought to be able to buy a used copy online, very cheap, if you want to read it again.