Merge UDT v4 changes into master

Bring master up to date with UDT v4 changes and other commits by ktarasz