fixed a bug in the profiler class
Merge origin/master