XMLNodeList const& devices = configuration_state->children();
for (XMLNodeList::const_iterator d = devices.begin(); d != devices.end(); ++d) {
XMLProperty* prop = (*d)->property (X_("name"));
- if (prop && prop->value() == device_name) {
+ if (prop && prop->value() == _device_info.name()) {
this_device = *d;
break;
}
delete _jog_wheel;
delete _port;
-
+ // the ports take time to release and we may be rebuilding right away
+ // in the case of changing devices.
+ g_usleep (100000);
DEBUG_TRACE (DEBUG::MackieControl, "Surface::~Surface done\n");
}