Several Compatibility- and bugfixes