fixes from Rune Christensen