Fixes that should go back into the master.
replaced hardcoded profile default
Merge pull request #518 from 28msec/FixesFromNTT

Fixes that should go back into the master.