Skip to content

mtsComponentManager::Connect() returns true even when interfaces fail to connect. #43

Open
@Will-McMahan

Description

@Will-McMahan

Hi,

I'm seeing some unexpected behavior using v1.0.6 on Ubuntu 14.04. When running the return value for mtsComponentManager::Connect() appears to be returning TRUE even when the interfaces were not successfully connected. In the code below, I expect the printed value ret to be 0, but I'm seeing 1.

#include <cisstMultiTask/mtsTaskManager.h>

int main ( int argc, char *argv[] )
{

    cmnLogger::SetMask ( CMN_LOG_ALLOW_DEFAULT );
    cmnLogger::SetMaskClassAll ( CMN_LOG_ALLOW_DEFAULT );
    cmnLogger::SetMaskFunction ( CMN_LOG_ALLOW_DEFAULT );
    cmnLogger::SetMaskDefaultLog ( CMN_LOG_ALLOW_DEFAULT );
    cmnLogger::AddChannel ( std::cout, CMN_LOG_ALLOW_DEFAULT );

    // Component manager
    mtsComponentManager *taskManager = mtsComponentManager::GetInstance();

    bool ret = taskManager->Connect ( "", "", "", "" );
    std::cout << "***" << ret << "***" << std::endl;

    return 0;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions