A gasfired appliance must have a listed shut off valve located in the same room as the appliance. What is the maximum distance allowed from the appliance to the shut off valve?

A gasfired appliance must have a listed shut off valve located in the same room as the appliance. What is the maximum distance allowed from the appliance to the shut off valve?