Fix issue #387