From: Peter Oliver <[email-masked]>
Date: Mon, 22 Dec 2014 20:34:49 +0000

I can reproduce this when electric-indent-mode is on and sh-set-shell
is run for a csh-family shell.  See also bug 19433, which causes this
problem to affect modes other than sh-mode.

-- 
Peter Oliver