Fixed some reg issues