summaryrefslogtreecommitdiff
path: root/libs/ardour/io.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libs/ardour/io.cc')
-rw-r--r--libs/ardour/io.cc12
1 files changed, 8 insertions, 4 deletions
diff --git a/libs/ardour/io.cc b/libs/ardour/io.cc
index 0d66da7795..5e9e5aa0c1 100644
--- a/libs/ardour/io.cc
+++ b/libs/ardour/io.cc
@@ -1040,7 +1040,8 @@ IO::make_connections_2X (const XMLNode& node, int /*version*/, bool in)
if (p != string::npos) {
ports[x].replace (p, 4, "/audio_out");
}
- nth(i)->connect (ports[x]);
+ if (NULL != nth(i).get())
+ nth(i)->connect (ports[x]);
}
}
@@ -1082,7 +1083,8 @@ IO::make_connections_2X (const XMLNode& node, int /*version*/, bool in)
if (p != string::npos) {
ports[x].replace (p, 3, "/audio_in");
}
- nth(i)->connect (ports[x]);
+ if (NULL != nth(i).get())
+ nth(i)->connect (ports[x]);
}
}
@@ -1606,8 +1608,10 @@ IO::connected_to (boost::shared_ptr<const IO> other) const
for (i = 0; i < no; ++i) {
for (j = 0; j < ni; ++j) {
- if (nth(i)->connected_to (other->nth(j)->name())) {
- return true;
+ if ((NULL != nth(i).get()) && (NULL != other->nth(j).get())) {
+ if (nth(i)->connected_to (other->nth(j)->name())) {
+ return true;
+ }
}
}
}