Skip to content
This repository has been archived by the owner on May 26, 2022. It is now read-only.

Wrong txtRecord format will crash app. #5

Closed
NeoLSN opened this issue May 31, 2016 · 4 comments
Closed

Wrong txtRecord format will crash app. #5

NeoLSN opened this issue May 31, 2016 · 4 comments

Comments

@NeoLSN
Copy link

NeoLSN commented May 31, 2016

java.lang.ArrayIndexOutOfBoundsException: src.length=38 srcPos=3 dst.length=103 dstPos=0 length=103
                                                                         at java.lang.System.arraycopy(Native Method)
                                                                         at com.apple.dnssd.TXTRecord.getValue(TXTRecord.java:219)
                                                                         at com.apple.dnssd.TXTRecord.getValueAsString(TXTRecord.java:230)
                                                                         at com.github.druk.rxdnssd.RxResolveListener.parseTXTRecords(RxResolveListener.java:57)
                                                                         at com.github.druk.rxdnssd.RxResolveListener.serviceResolved(RxResolveListener.java:42)
                                                                         at com.apple.dnssd.AppleService.ProcessResults(Native Method)
                                                                         at com.apple.dnssd.AppleService.run(DNSSD.java:693)
                                                                         at java.lang.Thread.run(Thread.java:818)

Do you have any idea about this?

@NeoLSN
Copy link
Author

NeoLSN commented May 31, 2016

Seems it happened when the txtRecord is in the wrong format.
I can not catch the exception by app.
It will crash app.

@NeoLSN NeoLSN changed the title ArrayIndexOutOfBoundsException Wrong txtRecord format will crash app. May 31, 2016
@NeoLSN
Copy link
Author

NeoLSN commented Jun 27, 2016

Where can I get a snapshot version to test?

@andriydruk
Copy link
Owner

I published new version to JCenter

compile 'com.github.andriydruk:rxdnssd:0.8.1'

@NeoLSN
Copy link
Author

NeoLSN commented Jun 28, 2016

Thanks.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants