Under some circumstances replace-match can crash emacs. It takes a lot to reproduce the crash and I haven't been able to find a minimal example. But I wonder if the backtrace that I captured in LLDB can give any clue to the clause? I can't reproduce the same crash in emacs24.