Remove HEAD unmerged references. (Copy full 1.11 file.)