bug fix from Johan Widen