Fixed terminal behaviour in IE with new emscripten compilation