Many more small fixes