Problem Definition
The code assumes that when a follower receives a proposal with POLRound == LockedRound, the locked value is equal to the proposed one (line). This follows from the 2/3 assumption (at least 2/3 of the voting power is under the control of correct validators), which guarantees that (*) a consensus round cannot generate two certificates (+2/3) for different values.
Proposal
I propose to log when a follower receives a proposal with POLRound == LockedRound and its locked value is different from the proposed one. This may indicate that the 2/3 assumption does not hold anymore. It should be discussed whether more drastic measures should be taken, as violating Property (*) may break safety.