Controlling by gas-analysis apparatus