bug fixes based on trials at abel.uio.no