Fix for issue #1566.