fixed error in set_data_reg() function