Fire safety is no accident, which is why building codes mandate the installation of fire doors to protect all occupants. During a fire, the doors compartmentalize the affected area to isolate the smoke and flames, and buy the occupants the time they need to exit the building safely.