~ci-train-bot/unity-api/unity-api-ubuntu-yakkety-landing-077

Viewing all changes in revision 238.2.1.

  • Committer: Stephen Kelly
  • Date: 2016-06-20 19:36:16 UTC
  • mto: This revision was merged to the branch mainline in revision 242.
  • Revision ID: steveire@gmail.com-20160620193616-or69stmcu6cceh73
Fix use of MockOptionSelectorFilter constructor

This just happens to compile because the bool casts to a null pointer for the
QString(const char*) constructor, and the this pointer casts to a bool.

GCC emits a warning for this:

MockFiltersModel.cpp: In constructor ‘MockFiltersModel::MockFiltersModel(unity::shell::scopes::ScopeInterface*)’:
MockFiltersModel.cpp:23:93: warning: converting ‘false’ to pointer type for argument 1 of ‘QString::QString(const char*)’ [-Wconversion-null]
     MockOptionSelectorFilter *f = new MockOptionSelectorFilter("f1", "Filter 1", false, this);
                                                                                             ^

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: