Fix protocol correction code