question

Carlos avatar image
Carlos asked

Whisperlink crash java.lang.StringIndexOutOfBoundsException: length

I don't have details about the crash as it came to me through Crashlytics but here is the exception: java.lang.StringIndexOutOfBoundsException: length=39; regionStart=0; regionLength=-1 at java.lang.String.startEndAndLength(String.java:504) at java.lang.String.substring(String.java:1333) at com.amazon.whisperlink.jmdns.impl.ServiceInfoImpl.decodeQualifiedNameMapForType(ServiceInfoImpl.java:294) at com.amazon.whisperlink.jmdns.impl.DNSRecord$Pointer.getServiceInfo(DNSRecord.java:509) at com.amazon.whisperlink.jmdns.impl.DNSRecord$Pointer.getServiceEvent(DNSRecord.java:520) at com.amazon.whisperlink.jmdns.impl.JmDNSImpl.updateRecord(JmDNSImpl.java:1336) at com.amazon.whisperlink.jmdns.impl.JmDNSImpl.handleRecord(JmDNSImpl.java:1479) at com.amazon.whisperlink.jmdns.impl.JmDNSImpl.handleQuery(JmDNSImpl.java:1549) at com.amazon.whisperlink.jmdns.impl.SocketListener.run(SocketListener.java:62)
amazon fling
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

memo@amazon avatar image
memo@amazon answered
Thanks for reporting this, Carlos! This network condition related exception is handled in the core engine and reported in the log for information purpose. Best regards,
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Carlos avatar image
Carlos answered
Crashlyics is reporting it as a crash, so I'm guessing that means the app crashed because it wasn't handled. The latest report I have is from July 27 java.lang.StringIndexOutOfBoundsException: length=33; regionStart=0; regionLength=-1 at java.lang.String.startEndAndLength(String.java:504) at java.lang.String.substring(String.java:1333) at com.amazon.whisperlink.jmdns.impl.ServiceInfoImpl.decodeQualifiedNameMapForType(ServiceInfoImpl.java:294) at com.amazon.whisperlink.jmdns.impl.DNSRecord$Pointer.getServiceInfo(DNSRecord.java:509) at com.amazon.whisperlink.jmdns.impl.DNSRecord$Pointer.getServiceEvent(DNSRecord.java:520) at com.amazon.whisperlink.jmdns.impl.JmDNSImpl.updateRecord(JmDNSImpl.java:1336) at com.amazon.whisperlink.jmdns.impl.JmDNSImpl.handleRecord(JmDNSImpl.java:1479) at com.amazon.whisperlink.jmdns.impl.JmDNSImpl.handleQuery(JmDNSImpl.java:1549) at com.amazon.whisperlink.jmdns.impl.SocketListener.run(SocketListener.java:62)
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

memo@amazon avatar image
memo@amazon answered
Hi Carlos, I understand now, and we are fixing the root cause. Would it be possible for you to give us the result of mDNS search? Please run the following command from a Mac or from a Windows PC (that has an installed version of dns-sd) on the same network. [b]> dns-sd -B _amzn-wplay._tcp . [/b] For dns-sd for Windows, you can install IBM Network IPS Thanks
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Carlos avatar image
Carlos answered
Sorry for the late response. Do you know if there is a way for me to get notifications when I have replies in this forum? I am already watching all my threads and I thought that would do it. Here is the output: dns-sd -B _amzn-wplay._tcp . Browsing for _amzn-wplay._tcp DATE: ---Tue 18 Aug 2015--- 11:03:57.163 ...STARTING... Timestamp A/R Flags if Domain Service Type Instance Name 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:3D144243BDFBC692CF9156140961E3A3:sw7Vr+6bbA:918441 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:4BAE8E0747B2D9E03DFDA96B4A9AA129:kmP+hMFWsu:773839 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:2BC065A1FD99DFFB5DC87FCE5B0FB92B:kmP+hMFWsu:158941 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:46293DB42F35DB944C26872C874E70E1:kmP+hMFWsu:338059 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:1CBB3F54EEB04B48481F75C1FBE889A9:kmP+hMFWsu:907589 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:46293DB42F35DB944C26872C874E70E1:kmP+hMFWsu:830205 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:F28EC4A7796FDD3A1CF2943BB7D65E76:kmP+hMFWsu:260599 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:4BAE8E0747B2D9E03DFDA96B4A9AA129:kmP+hMFWsu:811898 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:1CBB3F54EEB04B48481F75C1FBE889A9:kmP+hMFWsu:546721 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:46293DB42F35DB944C26872C874E70E1:kmP+hMFWsu:723812 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:F28EC4A7796FDD3A1CF2943BB7D65E76:kmP+hMFWsu:170986 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:F28EC4A7796FDD3A1CF2943BB7D65E76:kmP+hMFWsu:669479 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:4BAE8E0747B2D9E03DFDA96B4A9AA129:kmP+hMFWsu:467552 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:1CBB3F54EEB04B48481F75C1FBE889A9:kmP+hMFWsu:128576 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:46293DB42F35DB944C26872C874E70E1:kmP+hMFWsu:842543 11:03:57.164 Add 3 5 local. _amzn-wplay._tcp. amzn.dmgr:4BAE8E0747B2D9E03DFDA96B4A9AA129:kmP+hMFWsu:516521 11:03:57.164 Add 2 5 local. _amzn-wplay._tcp. amzn.dmgr:F28EC4A7796FDD3A1CF2943BB7D65E76:kmP+hMFWsu:909418
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Jamie Grossman avatar image
Jamie Grossman answered
Hi Carlos! This is great info. We have identified the underlying issue and will release the fix in the next update. We appreciate you bringing it to our attention. Best regards, Jamie
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Carlos avatar image
Carlos answered
Any idea when that release will happen? 25% of my users have my version with Fling support and this is by far my most reported crash on Crashlytics. 188 crashes for this vs 44 for the for the next crash down the list.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Bubblesoft avatar image
Bubblesoft answered
> Any idea when that release will happen? 25% of my > users have my version with Fling support and this is > by far my most reported crash on Crashlytics. 188 > crashes for this vs 44 for the for the next crash > down the list. I've only seen it happen a handful of times in my crash reports. However, I have some preventive code that disable Fling support for the user, if a Fling SDK crash such as this one is detected, to avoid repeated crashes.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Carlos avatar image
Carlos answered
This appears to be solved now, haven't received a single crash since updating to the latest sdk.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.