Lot of misc changes / fixes