A malfunctioning thermocouple can be reset by turning off the gas, cleaning the thermocouple's end, repositioning it closer to the flame, and then reigniting the pilot. If these steps fail, you might need to replace the thermocouple.