1

I have an app that uses com.dolby.dap.DsClientManager. When running on some Lenovo, Acer and ZTE devices I randomly get a NullPointerException

com.dolby.dap.DsClientManager$DsClientHandlerThread.handleMessage (DsClientManager.java:372)
android.os.Handler.dispatchMessage (Handler.java:106)
android.os.Looper.loop (Looper.java:193)
android.os.HandlerThread.run (HandlerThread.java:61)

Has anyone else seen this issue? Is there a way to fix it?

Please also notice that the exception is not thrown when I call one of the dolby APIs since I'm catching all the Runtime exceptions every time. The exception is thrown asynchronously.

kingston
  • 11,053
  • 14
  • 62
  • 116
  • If you don't post the stacktrace and code causing this, I highly doubt anyone can answer this. You're assuming it's an Android bug when it could be a bug in your code. – m0skit0 Jan 26 '15 at 12:32
  • The reason why I'm quite sure it is not in my code is that it is very random, it is only on some devices and it is not when I call one of the APIs. I added all the stacktrace but as you can see it does not tell you much more then before. – kingston Jan 26 '15 at 12:57
  • Generally you should assume bug comes from your code. Randomness also is usual when dealing with threads. Still waiting for the code ;) – m0skit0 Jan 26 '15 at 12:58
  • it's just too big to be posted here and I'm not expecting anyone to debug my code. I just need to know whether someone else is seeing the same issue. As you can see the crash is asynchronous so I would need to post the entire code – kingston Jan 26 '15 at 13:01
  • http://sscce.org/ - if nobody reported such an issue, then most likely it's a problem in your code. As I said, it's common when multi-threading the wrong way. – m0skit0 Jan 26 '15 at 14:23

1 Answers1

1

It seems to be a bug in the dolby audio processing library. Apparently there are some devices (e.g., Acer A3-A20 and Lenovo B8000) where the dolby.ds.state system property is present, but nevertheless the dolby audio processing library fails to instantiate the client? When this occurs, the library assumes DS is available, but subsequently fails to instantiate the client and then tries to invoke the .init() method on a null instance.

Joe Bowbeer
  • 3,574
  • 3
  • 36
  • 47