Fix error for wrong use of reset().