I ate something unagreeable last pm. It did not produce diahra but only twisting stomach pain. What medicine is safe to take giving I am still nursing?

Abdominal pain. Pepto-bismol is very safe as it mostly stays in the GI tract and isn't absorbed into the blood stream. Pepto-bismol will cause your stool to be black. However, if this doesn't get better fairly quickly or it worsens, you should be seen by a physician. Abdominal pain can be a symptom of a number of serious problems that need a doctor's immediate attention.
Zantac (ranitidine) probably safe. Zantac (ranitidine) is considered to be probably safe during breastfeeding.