When you think of safety mishaps at hospitals, what likely comes to mind is patients who got surgery on the wrong leg or were exposed to deadly bacteria. Those are problems that have received widespread attention from safety experts.

A recent report by the Pennsylvania Patient Safety Authority highlights another potential danger in hospitals: food.

Snicker all you like about the quality of hospital food. That's not what the report was about. It looked at mistakes involving patients with special dietary needs who got the wrong food. These were no laughing matter.

Patient safety analyst Susan Wallace found 285 such mistakes between January 2009 and June 2014. Eight of them - all involved patients eating food to which they were allergic - resulted in serious harm.

Allergy mistakes accounted for 181 of the reported "events." Others included patients getting the wrong kind of diet, getting meals meant for other patients, and getting food when they were supposed to be fasting.

The potential health consequences included severe allergic reactions, swallowing problems, and exacerbations of illnesses like diabetes. People who are not supposed to eat but do may have to have surgery rescheduled.

In the report, published this month in the authority's newsletter, Wallace described several of the worst mistakes.

In one, a patient allergic to seafood was given fish. The patient then needed several intravenous medications, a shot of epinephrine, and intensive care observation. Another was allergic to pineapple but was given a fruit cup containing pineapple. (The allergy had been noted in the patient's records under drugs, not food.) The patient ate the other fruits and still had an allergic reaction that required intubation and a transfer to a critical care unit.

All of the patients eventually recovered.

In a near miss, a patient's family flagged a tray that contained fish for lunch. The patient's allergy to seafood had been recorded on the chart as an allergy to "seawater."

Wallace works for the ECRI Institute, a Plymouth Meeting organization known for testing medical products and processes. It contracts with the authority, an independent state agency, to study mandatory reports of safety incidents in health-care facilities.

Wallace said she noticed several reports of food problems and thought it was an issue worth more attention. Because hospitals don't see one another's reports, they may not realize how common certain mistakes are.

"What I want to do is educate the hospitals and say, 'Hey, look what's going on,' " Wallace said.

Studies show 4 percent of American adults and 8 percent of children have food allergies, she said.

Getting patients the right food for their diets - let alone hot, tasty food - requires good communication among doctors, nurses, food preparers, and the people who deliver the trays.

Wallace said there can be problems because food service workers don't see the whole electronic medical record. Everyone in a hospital needs to know where food allergies will be in the record so the people who make and deliver the food get the message about what specific patients can eat.

One hospital combated mix-ups by creating food wheels - signs nurses could adjust to notify everyone about what patients were allowed to eat.

Wallace recommended continuing education on diet and allergies for hospital staff, plus written procedures on how to handle special needs.

Patients and their families also need to be alert.