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

Array copy ArrayIndexOutOfBoundsException #177

Open
galderz opened this issue Feb 2, 2023 · 2 comments
Open

Array copy ArrayIndexOutOfBoundsException #177

galderz opened this issue Feb 2, 2023 · 2 comments

Comments

@galderz
Copy link
Contributor

galderz commented Feb 2, 2023

Unable to run helloworld, it sometimes fails with:

Caused by: java.lang.ArrayIndexOutOfBoundsException: arraycopy: last destination index 10240 out of bounds for byte[8192]
	at java.lang.System.arraycopy(Native Method) ~[?:?]
	at io.hyperfoil.tools.qdup.stream.LineEmittingStream.write(LineEmittingStream.java:97) ~[qDup-0.6.17-SNAPSHOT-uber.jar:?]
	at io.hyperfoil.tools.qdup.stream.MultiStream.write(MultiStream.java:126) ~[qDup-0.6.17-SNAPSHOT-uber.jar:?]
	at io.hyperfoil.tools.qdup.stream.FilteredStream.superWrite(FilteredStream.java:112) ~[qDup-0.6.17-SNAPSHOT-uber.jar:?]
	at io.hyperfoil.tools.qdup.stream.FilteredStream.write(FilteredStream.java:222) ~[qDup-0.6.17-SNAPSHOT-uber.jar:?]
	at io.hyperfoil.tools.qdup.stream.MultiStream.write(MultiStream.java:126) ~[qDup-0.6.17-SNAPSHOT-uber.jar:?]
	at io.hyperfoil.tools.qdup.stream.SuffixStream.superWrite(SuffixStream.java:149) ~[qDup-0.6.17-SNAPSHOT-uber.jar:?]
	at io.hyperfoil.tools.qdup.stream.SuffixStream.write(SuffixStream.java:211) ~[qDup-0.6.17-SNAPSHOT-uber.jar:?]
	... 26 more

Full stacktrace can be found here.

Client env is macOS and server Fedora. Java version 17.

@johnaohara
Copy link
Member

After digging, this is the same issue as #178, closing this issue and will resolve in #178

@johnaohara
Copy link
Member

Thinking about it some more, we want a bounds check to ensure we correctly handle the buffer overflow, am re-opening

@johnaohara johnaohara reopened this Feb 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants