fixed all bugs reported by the static analyzer

they were only about dead initial store