user1253847
user1253847

Reputation: 5451

java : Tracing out the Error line in my case

I am working on a existing Java EE based application . Somehow the functionality is not working written by them .

When i found out the logs in Linux server i found out this Exception there

Caused by: java.lang.ArrayIndexOutOfBoundsException: 1
at com.cyber.EasyOptions.view(EasyOptions.java:2054)

What does this mean exactly ??

  1. I guess there is a class named EasyOptions and in that there is a method view and inside it there is this Exception occuring ??

This particular class EasyOptions is present inside a jar file in our code .

I am using JD-GUI decompiler and when navigated to this particualr jar , and saw this class EasyOptions , inside view method there is no such line (2054) so dont know we can match the line numbers this way or not ??

I guess we cant match line numbers this way , my questions how can we trace out the exact line of error ??

Upvotes: 1

Views: 91

Answers (1)

NPE
NPE

Reputation: 500357

guess there is a class named EasyOptions and in that there is a method view and inside it there is this Exception occuring ??

That's correct.

I am using JD-GUI decompiler and when navigated to this particualr jar , and saw this class EasyOptions , inside view method there is no such line (2054)

The line number only makes sense in the context of the original source code. The decompiled code isn't identical to the original and will have different line numbering.

how can we trace out the exact line of error

Without the original source code it's going to be tricky. One way to narrow down the possibilities is to look through the decompiled code for EasyOptions.view(), looking for places where an array is being accessed.

Upvotes: 3

Related Questions