Fix lazy search and replace.