fix assert

This commit is contained in:
Andrew Meadows 2018-02-09 15:47:38 -08:00
parent d59c3898dc
commit 2b1b75450d

View file

@ -32,7 +32,7 @@ class JobNoIO {};
class JobContext { class JobContext {
public: public:
JobContext(const QLoggingCategory& category) : profileCategory(category) { JobContext(const QLoggingCategory& category) : profileCategory(category) {
assert(category); assert(&category);
} }
virtual ~JobContext() {} virtual ~JobContext() {}
@ -167,8 +167,7 @@ public:
virtual void run(const ContextPointer& jobContext) { virtual void run(const ContextPointer& jobContext) {
PerformanceTimer perfTimer(_name.c_str()); PerformanceTimer perfTimer(_name.c_str());
//PROFILE_RANGE(foo, _name); // NOTE: rather than use the PROFILE_RANGE macro, we create a Duration manually
//Duration profileRangeThis(trace_foo(), name);
Duration profileRange(jobContext->profileCategory, _name.c_str()); Duration profileRange(jobContext->profileCategory, _name.c_str());
auto start = usecTimestampNow(); auto start = usecTimestampNow();