Fix issue #1224