Revert "Merge pull request #1986 from matham/master"

This reverts commit cb26c0b8cb00d18c75503ce4ee59a95a619e8189, reversing
changes made to bb8c7428ab40dde4af92e696ff518e82e214cd24.