bugfixes, minor changes