A few small fixes (so I can rebase after latest commit).