Fix reservation of caret position on remask