MANY bugfixes.