Small bugfixes that were detected when running models in OpenModelica.