Coprophagia, or the eating of stool (feces) or bowel movements, is a relatively common problem in dogs. There are both medical and behavioral reasons why dogs eat feces. You may be able to stop your dog from eating his own feces by altering the taste of the feces. This can be done by placing a substance on the feces that has an unpleasant taste. Some limited success has been received with injecting pepper juice into the feces or applying seasoning salt or meat tenderizer to the food.
For more information, read the article Coprophagia.