issue-232: fix for endless loop