summaryrefslogtreecommitdiffstats
path: root/src/server/events
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/events')
-rw-r--r--src/server/events/Connect.cpp2
-rw-r--r--src/server/events/Disconnect.cpp9
2 files changed, 6 insertions, 5 deletions
diff --git a/src/server/events/Connect.cpp b/src/server/events/Connect.cpp
index e02b19a8..c75e56a1 100644
--- a/src/server/events/Connect.cpp
+++ b/src/server/events/Connect.cpp
@@ -153,7 +153,7 @@ void
Connect::execute(RunContext& context)
{
if (_status == Status::SUCCESS) {
- _head->add_arc(context, _arc.get());
+ _head->add_arc(context, *_arc.get());
if (!_head->is_driver_port()) {
_head->set_voices(context, std::move(_voices));
}
diff --git a/src/server/events/Disconnect.cpp b/src/server/events/Disconnect.cpp
index 9320163a..176f0999 100644
--- a/src/server/events/Disconnect.cpp
+++ b/src/server/events/Disconnect.cpp
@@ -170,11 +170,12 @@ Disconnect::pre_process(PreProcessContext& ctx)
bool
Disconnect::Impl::execute(RunContext& context, bool set_head_buffers)
{
- ArcImpl* const port_arc = _head->remove_arc(context, _tail);
-
- if (!port_arc) {
+ if (!_arc) {
return false;
- } else if (_head->is_driver_port()) {
+ }
+
+ _head->remove_arc(*_arc.get());
+ if (_head->is_driver_port()) {
return true;
}