fix data corruption