Fixing debug in Media Kit.

* Only fixing debug i the media kit.
* Help with ASSERT(flavorID == testFlavorID) would be nice, don't know what ASSERT do.
This commit is contained in:
Fredrik Modéen
2012-01-29 00:06:13 +01:00
parent d456de037d
commit e817f41e8b
4 changed files with 7 additions and 8 deletions
+1 -1
View File
@@ -1921,7 +1921,7 @@ BMediaRosterEx::RegisterNode(BMediaNode* node, media_addon_id addOnID,
BMediaAddOn* addon = node->AddOn(&testFlavorID); BMediaAddOn* addon = node->AddOn(&testFlavorID);
ASSERT(addOnID == (addon != NULL ? addon->AddonID() : -1)); ASSERT(addOnID == (addon != NULL ? addon->AddonID() : -1));
ASSERT(flavorID == testFlavorID); // ASSERT(flavorID == testFlavorID);
); );
server_register_node_request request; server_register_node_request request;
+1 -1
View File
@@ -241,7 +241,7 @@ PluginManager::DestroyWriter(Writer* writer)
{ {
if (writer != NULL) { if (writer != NULL) {
TRACE("PluginManager::DestroyWriter(%p (plugin: %p))\n", writer, TRACE("PluginManager::DestroyWriter(%p (plugin: %p))\n", writer,
reader->fMediaPlugin); writer->fMediaPlugin);
// NOTE: We have to put the plug-in after deleting the writer, // NOTE: We have to put the plug-in after deleting the writer,
// since otherwise we may actually unload the code for the // since otherwise we may actually unload the code for the
// destructor... // destructor...
+1 -2
View File
@@ -284,8 +284,7 @@ NodeManager::ReleaseNodeReference(media_node_id id, team_id team)
status_t status_t
NodeManager::ReleaseNodeAll(media_node_id id) NodeManager::ReleaseNodeAll(media_node_id id)
{ {
TRACE("NodeManager::ReleaseNodeAll enter: node %ld, team %ld\n", node.node, TRACE("NodeManager::ReleaseNodeAll enter: node %ld\n", id);
team);
BAutolock _(this); BAutolock _(this);
+4 -4
View File
@@ -470,7 +470,7 @@ MediaAddonServer::_ScanAddOnFlavors(BMediaAddOn* addon)
int32 newFlavorCount = addon->CountFlavors(); int32 newFlavorCount = addon->CountFlavors();
info.flavor_count = newFlavorCount; info.flavor_count = newFlavorCount;
TRACE("%ld old flavors, %ld new flavors\n", oldflavorcount, newFlavorCount); TRACE("%ld old flavors, %ld new flavors\n", oldFlavorCount, newFlavorCount);
// during the first update (i == 0), the server removes old dormant_flavor_infos // during the first update (i == 0), the server removes old dormant_flavor_infos
for (int i = 0; i < newFlavorCount; i++) { for (int i = 0; i < newFlavorCount; i++) {
@@ -720,7 +720,7 @@ MediaAddonServer::_InstantiatePhysicalInputsAndOutputs(AddOnInfo& info)
dormantNodeInfo.flavor_id = flavorinfo->internal_id; dormantNodeInfo.flavor_id = flavorinfo->internal_id;
strcpy(dormantNodeInfo.name, flavorinfo->name); strcpy(dormantNodeInfo.name, flavorinfo->name);
PRINT("MediaAddonServer::InstantiatePhysialInputsAndOutputs: " TRACE("MediaAddonServer::InstantiatePhysialInputsAndOutputs: "
"\"%s\" is a physical input/output\n", flavorinfo->name); "\"%s\" is a physical input/output\n", flavorinfo->name);
status_t status = fMediaRoster->InstantiateDormantNode( status_t status = fMediaRoster->InstantiateDormantNode(
dormantNodeInfo, &node); dormantNodeInfo, &node);
@@ -729,7 +729,7 @@ MediaAddonServer::_InstantiatePhysicalInputsAndOutputs(AddOnInfo& info)
"Couldn't instantiate node flavor, internal_id %ld, " "Couldn't instantiate node flavor, internal_id %ld, "
"name %s\n", flavorinfo->internal_id, flavorinfo->name); "name %s\n", flavorinfo->internal_id, flavorinfo->name);
} else { } else {
PRINT("Node created!\n"); TRACE("Node created!\n");
info.active_flavors.push_back(node); info.active_flavors.push_back(node);
} }
} }
@@ -744,7 +744,7 @@ MediaAddonServer::_InstantiateAutostartFlavors(AddOnInfo& info)
return; return;
for (int32 index = 0;; index++) { for (int32 index = 0;; index++) {
PRINT("trying autostart of node %ld, index %ld\n", info.id, index); TRACE("trying autostart of node %ld, index %ld\n", info.id, index);
BMediaNode* node; BMediaNode* node;
int32 internalID; int32 internalID;