Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix BluetoothMedic crash when started on non-looper thread. #981

Merged
merged 2 commits into from
Jun 11, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

- Parse multiple manufacturer sections in the advertisement and the scan response to look for beacons. (#970, David G. Young)
- Improve HW filter detection mechanism in order to detect beacons immediately after starting in background (#974, Vlad Vladau)
- Fix crash on BluetoothMedic when started on thread without a looper (#980, David G. Young)

### 2.17 / 2020-04-19

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import android.content.IntentFilter;
import android.os.Build;
import android.os.Handler;
import android.os.Looper;
import android.os.PersistableBundle;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
Expand Down Expand Up @@ -86,7 +87,7 @@ public class BluetoothMedic {
@Nullable
private LocalBroadcastManager mLocalBroadcastManager;
@NonNull
private Handler mHandler = new Handler();
private Handler mHandler = new Handler(Looper.getMainLooper());
private int mTestType = 0;
@Nullable
private Boolean mTransmitterTestResult = null;
Expand Down