In September, we reported on the death of Robert Rippingale, a 31-year-old Jetstar passenger who passed away on a flight from Singapore to Auckland.

Rippingale choked to death while eating dinner, and although a doctor and two nurses were onboard, they were unable to resuscitate him.

Although such tragedies are very rare, in-flight deaths are eventualities that airlines have to be prepared for. “It’s one of those things that's very unusual but that doesn’t make it any less difficult to deal with,” said Heidi Macfarlane, a protocol expert and vice president of strategic development for MedAire, a company that provides airlines with on-the-ground medical support. “Whether you're the person who dies or a family member or crew member, it's a difficult situation.”

MedAire provides 24-hour support to more than 60 commercial airlines worldwide. In 2010, the company received more than 19,000 calls about in-flight medical emergencies. Of those cases, 94 people died.

In order to understand how airlines and MedAire doctors respond to deaths, it is important to understand why deaths occur in the first place. “There are three categories of people who could die onboard,” said Dr Paulo Alves, vice president of aviation and maritime health for MedAire. The first is someone for whom a medical emergency is completely unexpected. The second is someone who is terminally ill and is travelling specifically for medical purposes. The third is someone who knows he or she is sick, but wants to travel anyway, often without consulting a doctor.

Unexpected medical emergencies include heart attacks, strokes or accidents such as choking. In 2009, for example, the captain of a Continental Airlines flight died of a heart attack mid-flight. There is always at least one co-pilot in the cockpit in addition to the captain, and in this case there were two co-pilots who continued flying the plane and landed it safely at Newark Liberty International. In order to avoid panic, the crew did not tell passengers what had happened.

Terminally ill patients are usually on stretchers and may be travelling for the express purpose of dying in a particular location. Airlines are made aware of such passengers and can try to make space on larger planes to accommodate them.

“The most important category for me is the third one,” Dr Alves said. “Many times [these patients] are not aware of the possible consequences of [being in] an aircraft [environment]. Sometimes, they never checked with any doctor whether it is appropriate or not [to fly].” These are “determined travellers” – people who may be desperate to get back home or who have made non-refundable travel arrangements and don’t want to miss their trip. “We see this very often, actually,” said Dr Alves. “Those are typically tragic circumstances [because they] can be avoided by better education.”

MedAire had a recent case in which a couple asking for extra air sickness bags was discovered to have norovirus, commonly called “the cruise ship virus”. Since the plane hadn’t yet taken off, the two sick passengers were taken off the flight. The next day, the couple realized they would be able to fly as long as they didn’t say anything to the flight attendants. “We received another in-flight medical call from the airline saying the passenger was still vomiting and was dehydrated,” recalled Macfarlane. In 2010, MedAire received more than 12,000 calls for similar cases.

So, how does an airline respond when one of these cases results in a death? Depending on the airline, flight crews may receive instructions from on-the-ground medical professionals on how to proceed. “It’s not automatic that a flight would divert if someone expires onboard,” said Macfarlane.

“Sometimes in the end, individuals with the deceased would rather carry on to their destination,” explained Dr. Alves. For family members or friends of the victim, dealing with human remains becomes more complicated in an unfamiliar location.

There can be reasons for diverting a flight, though. “Let's say they're travelling from the east coast to the west coast of the US, and they’re only an hour into the flight, and it's a small aircraft and every seat is occupied,” Macfarlane described. “[The crew] may make a decision that travelling four more hours with human remains onboard is too much emotionally for the crew or the family.”

Then there’s the issue of how flight attendants handle the body of someone who has passed away. Sometimes flight attendants strap the person back into his or her seat, which is often the safest option for nearby passengers. Putting a body in a lavatory or in the aisle would be a violation of safety regulations. And there may not be a row with enough free seats to lay the body across.

If there is not a proper space elsewhere on the plane, Singapore Airlines actually has a compartment on its A340-500 aircraft that can hold the body of someone who has died. The A340-500 flies the longest duration and distance flight in the world, a nonstop 18-hour flight from Newark to Singapore. “So that creates a whole host of new realities in terms of how you manage the flight process,” said spokesman James Boyd. This flight also has two full sets of cockpit crew and two full sets of cabin crew to help plan ahead for emergencies.

Southwest Airlines flight attendants are trained to perform resuscitation until the airline’s medical consultant advises them to stop, but they do not have staff members onboard who are qualified to call a time of death. “We technically don’t have any mid-flight deaths,” said spokeswoman Katie McDonald. Cruise ships, on the other hand, do have medical professionals onboard. They also often have morgues to preserve a body in case of death.

About 10 to 12 million people go on cruises each year, many of them elderly, so deaths are bound to occasionally occur. Just this fall, two separate, unrelated deaths occurred on a Norwegian Dawn cruise to Bermuda, both stemming from natural causes.

Since cruise ships can hold thousands of passengers who eat together, drink together and sometimes engage in risky behaviours, there can be safety concerns. Foodborne illnesses, such as norovirus, are common on cruise ships, so experts recommend being diligent about washing your hands regularly. Substance-fuelled accidents can also take place, such as falling overboard. Deaths on cruises are most commonly the result of natural causes, though, often due to old age.

Whether a death occurs during air travel or sea travel, almost every case is different. “Each situation is unique,” said Ed Martelle, a spokesman for American Airlines, “so we do not have a ‘one-size-fits-all’ approach.”

Travelwise is a BBC Travel column that goes behind the travel stories to answer common questions, satisfy uncommon curiosities and uncover some of the mystery surrounding travel. If you have a burning travel question, contact Travelwise.