fixes to merge from master