Code cleanup.
Merge pull request #3810 from Segrain/master

Smallfix.