Merge pull request #7382 from Segrain/master

Bugfixes.