diff --git a/prep_code.sh b/prep_code.sh
index db65c92fb65d23b213960a5d71805f9ab0fb375b..2ddfee66cc55c905c9414dd9c1a5ba573ada7e88 100755
--- a/prep_code.sh
+++ b/prep_code.sh
@@ -169,6 +169,7 @@ if [ -n "${mnh_expand_options-}" ]; then
       [ $verbose -gt 1 ] && echo "Applying mnh_expand on $1"
       $PHYEXTOOLSDIR/correct_indent.py $1 "detect"
       mnh_expand -DMNH_EXPAND_NOCPP $mnh_expand_options $1_EXPAND > tempo_mnh_expand
+      rm -f $1_EXPAND
       $PHYEXTOOLSDIR/correct_indent.py tempo_mnh_expand "indent"
       mv tempo_mnh_expand_CORRECT_INDENT $1
     fi