A few small bugfixes.