A novel approach to on-line measurement of gas evolution kinetics: Application to the negative difference effect of Mg in chloride solution