fix for issue #561