Fix for issue #618