Skip to content

Commit

Permalink
Fix issues from refactoring for VirtualRekordbox
Browse files Browse the repository at this point in the history
  • Loading branch information
brunchboy committed May 5, 2024
1 parent 1899723 commit beef234
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/main/java/org/deepsymmetry/beatlink/VirtualCdj.java
Original file line number Diff line number Diff line change
Expand Up @@ -986,7 +986,7 @@ public void run() {
try {
if (received && (packet.getAddress() != socket.get().getLocalAddress())) {
DeviceUpdate update = buildUpdate(packet);
if (update != null) {
if (update != null && isRunning()) {
processUpdate(update);
}
}
Expand Down Expand Up @@ -1145,13 +1145,13 @@ public synchronized void stop() {
matchingInterfaces.clear();
updates.clear();
setTempoMaster(null);
setDeviceNumber((byte)0); // Set up for self-assignment if restarted.

if (inOpusQuadCompatibilityMode()) {
// We were running in proxy mode, so we need to shut down VirtualRekordbox, and nothing further.
VirtualRekordbox.getInstance().stop();
proxyingForVirtualRekordbox.set(false);
deliverLifecycleAnnouncement(logger, false);
setDeviceNumber((byte)0); // Set up for self-assignment if restarted.
return;
}

Expand All @@ -1165,6 +1165,7 @@ public synchronized void stop() {
socket.get().close();
socket.set(null);
deliverLifecycleAnnouncement(logger, false);
setDeviceNumber((byte)0); // Set up for self-assignment if restarted.
}
}

Expand Down

0 comments on commit beef234

Please sign in to comment.