Mercurial > hg > svcore
changeset 1167:7c4f4701b49f
Debug bits
author | Chris Cannam |
---|---|
date | Fri, 22 Jan 2016 09:52:08 +0000 |
parents | 4607603c46d0 |
children | 52d088c24c5c |
files | plugin/FeatureExtractionPluginFactory.cpp |
diffstat | 1 files changed, 10 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/plugin/FeatureExtractionPluginFactory.cpp Tue Jan 19 12:32:30 2016 +0000 +++ b/plugin/FeatureExtractionPluginFactory.cpp Fri Jan 22 09:52:08 2016 +0000 @@ -164,7 +164,7 @@ QObject::tr("<b>Failed to load plugins</b>" "<p>Failed to load one or more plugin libraries:</p>\n"); warningMessage += "<ul>"; - for (int i = 0; i < bad.size(); ++i) { + for (int i = 0; in_range_for(bad, i); ++i) { QString m; if (badStatuses[i] == PluginLoadFailedToLoadLibrary) { m = QObject::tr("Failed to load library"); @@ -376,7 +376,9 @@ QString type, soname, label; PluginIdentifier::parseIdentifier(identifier, type, soname, label); if (type != "vamp") { - cerr << "FeatureExtractionPluginFactory::instantiatePlugin: Wrong factory for plugin type " << type << endl; +#ifdef DEBUG_PLUGIN_SCAN_AND_INSTANTIATE + cerr << "FeatureExtractionPluginFactory::instantiatePlugin: Wrong factory for plugin type " << type << endl; +#endif return 0; } @@ -439,7 +441,9 @@ } } -// SVDEBUG << "FeatureExtractionPluginFactory::instantiatePlugin: Instantiated plugin " << label << " from library " << soname << ": descriptor " << descriptor << ", rv "<< rv << ", label " << rv->getName() << ", outputs " << rv->getOutputDescriptors().size() << endl; +#ifdef DEBUG_PLUGIN_SCAN_AND_INSTANTIATE + cerr << "FeatureExtractionPluginFactory::instantiatePlugin: Instantiated plugin " << label << " from library " << soname << ": descriptor " << descriptor << ", rv "<< rv << ", label " << rv->getName() << ", outputs " << rv->getOutputDescriptors().size() << endl; +#endif return rv; } @@ -449,7 +453,9 @@ { void *handle = m_handleMap[plugin]; if (handle) { -// SVDEBUG << "unloading library " << handle << " for plugin " << plugin << endl; +#ifdef DEBUG_PLUGIN_SCAN_AND_INSTANTIATE + cerr << "unloading library " << handle << " for plugin " << plugin << endl; +#endif DLCLOSE(handle); } m_handleMap.erase(plugin);