avoid redundant work when there are multiple inserts during an edit sequence) closes PR 12897
fprintf' ->