Merged updates from other project. Bug fixes.