minor bugfix from upstream