Method of treating optical equipment, especially optical equipment for preventing the formation of fungi on parts located in the hollow interior of the equipment. The interior of the equipment is charged with a sterilising gas, especially ethylene oxide. The sterilising gas is stored in the interior in a porous material capable of absorbing gas, and thereafter the interior is closed in an essentially gas-tight manner. The sterilising gas stored in the porous material creates a sterile or sterilising atmosphere with the air and humidity contained in the interior for a long time, so that there can be no infestation with fungi on parts located in the interior of the equipment, e.g. optical lenses and mirrors.