Draft version of a fix for issue #65.