fixes internal memory