fix bug #489 from #429