Possible fix for bug #821.