diff options
author | Tuan Nguyen <tnguy238@ford.com> | 2017-05-24 10:01:53 -0700 |
---|---|---|
committer | Tuan Nguyen <tnguy238@ford.com> | 2017-05-24 10:01:53 -0700 |
commit | fddca9a10b07e78499dd38c29db6873ad3aef246 (patch) | |
tree | 960f1c1ecb50739441480a89eef59543ed303bac /sdl_android | |
parent | bb8d13b8ec49006be38b46521c6e3219017153dd (diff) | |
download | sdl_android-fddca9a10b07e78499dd38c29db6873ad3aef246.tar.gz |
#464 Perform null check before init Looperbugfix/issue_464
Diffstat (limited to 'sdl_android')
-rw-r--r-- | sdl_android/src/androidTest/java/com/smartdevicelink/transport/SdlRouterServiceTests.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sdl_android/src/androidTest/java/com/smartdevicelink/transport/SdlRouterServiceTests.java b/sdl_android/src/androidTest/java/com/smartdevicelink/transport/SdlRouterServiceTests.java index 83e9a7780..36274b99d 100644 --- a/sdl_android/src/androidTest/java/com/smartdevicelink/transport/SdlRouterServiceTests.java +++ b/sdl_android/src/androidTest/java/com/smartdevicelink/transport/SdlRouterServiceTests.java @@ -34,7 +34,9 @@ public class SdlRouterServiceTests extends AndroidTestCase { * msg.what == TransportConstants.ROUTER_RECEIVED_PACKET */ public void testAlTransportHandlerHandleNullBundle() { - Looper.prepare(); + if (Looper.myLooper() == null) { + Looper.prepare(); + } class AltTransportHandler extends Handler { ClassLoader loader; final WeakReference<SdlRouterService> provider; |