Fix cleanup in case of error.
Fix cleanup in case of error.

zcsteele/turbo,YuanPeir-Chen/turbo-support-mipsel,kernelsauce/turbo,ddysher/turbo,ddysher/turbo,mniestroj/turbo,zcsteele/turbo,YuanPeir-Chen/turbo-support-mipsel,luastoned/turbo,luastoned/turbo