Reading the crash log
up vote
1
down vote
favorite
I see ArrayIndexOutOfBounds Exception thrown but there are three different methods in the following lines in the code.How would I read the log to find out which of the following lines the error being thrown at. Please advise.
ServerImpl.java:1870 or ServerImpl.java:1750 or TrackLocation.java:52
Code:
TrackLocation.java:52 -
int successFlg = Server.instance.updateLocationInServer(lat, lot,
System.currentTimeMillis(), true);
ServerImpl.java:1750 -
addOfflineCommand("locationService", lat, lot, System.currentTimeMillis());
ServerImpl.java:1870 -
Storage.getInstance().writeObject(appName + user + "-
offlineCommandsLocEnc", l_noAppt);
Initializing the Storage:
public void init(Object context) {
Preferences.setPreferencesLocation("EncryptedPreferences");
Storage.getInstance().deleteStorageFile(Cookie.STORAGE_NAME);
}
public class TrackLocation implements LocationListener {
private static TrackLocation instance = new TrackLocation();
private Location lastLocation;
private Timer time;
public static TrackLocation getInstance() {
return instance;
}
public void stopTracking() {
if (time != null) {
time.cancel();
}
time = null;
LocationManager.getLocationManager().setLocationListener(null);
}
public void startTracking() {
if (time != null) {
stopTracking();
}
if (Preferences.get("LocationTracking", true)) {
long delay = Server.instance.getLoctionPollingIntervalMillis();
LocationManager.getLocationManager().setLocationListener(this,
new LocationRequest(LocationRequest.PRIORITY_HIGH_ACCUARCY, delay));
time = new Timer();
time.schedule(new TimerTask() {
@Override
public void run() {
if (lastLocation != null) {
double lat = (double) lastLocation.getLatitude();
double lot = (double) lastLocation.getLongitude();
int successFlg = Server.instance.updateLocationInServer(lat, lot, System.currentTimeMillis(), true);
}
}
}, 30000, delay);
}
}
@Override
public void locationUpdated(Location location) {
lastLocation = location;
}
@Override
public void providerStateChanged(int newState) {
}
}
Error Log:
java.lang.ArrayIndexOutOfBoundsException:
at java.lang.System.arraycopy (Native Method)
at org.a.a.c.c.a (PaddedBufferedBlockCipher.java:203)
at com.codename1.e.a$a.write (EncryptedStorage.java:150)
at sun.nio.cs.StreamEncoder.writeBytes (StreamEncoder.java:221)
at sun.nio.cs.StreamEncoder.implWrite (StreamEncoder.java:282)
at sun.nio.cs.StreamEncoder.write (StreamEncoder.java:125)
at sun.nio.cs.StreamEncoder.write (StreamEncoder.java:135)
at java.io.OutputStreamWriter.write (OutputStreamWriter.java:220)
at java.io.PrintWriter.write (PrintWriter.java:456)
at java.io.PrintWriter.write (PrintWriter.java:473)
at java.io.PrintWriter.print (PrintWriter.java:603)
at java.io.PrintWriter.println (PrintWriter.java:756)
at java.lang.Throwable$WrappedPrintWriter.println (Throwable.java:755)
at java.lang.Throwable.printStackTrace (Throwable.java:650)
at java.lang.Throwable.printStackTrace (Throwable.java:712)
at com.codename1.impl.android.c.a (AndroidImplementation.java:5937)
at com.codename1.h.l.b (Log.java:347)
at com.codename1.h.l.a (Log.java:324)
at com.codename1.h.s.a (Storage.java:228)
at com.xxxx.xxxxxx.b.n.a (ServerImpl.java:1870)
at com.xxxx.xxxxxx.b.n.a (ServerImpl.java:1750)
at com.xxxx.xxxxxx.c.a$1.run (TrackLocation.java:52)
at java.util.TimerThread.mainLoop (Timer.java:555)
at java.util.TimerThread.run (Timer.java:505)
codenameone
add a comment |
up vote
1
down vote
favorite
I see ArrayIndexOutOfBounds Exception thrown but there are three different methods in the following lines in the code.How would I read the log to find out which of the following lines the error being thrown at. Please advise.
ServerImpl.java:1870 or ServerImpl.java:1750 or TrackLocation.java:52
Code:
TrackLocation.java:52 -
int successFlg = Server.instance.updateLocationInServer(lat, lot,
System.currentTimeMillis(), true);
ServerImpl.java:1750 -
addOfflineCommand("locationService", lat, lot, System.currentTimeMillis());
ServerImpl.java:1870 -
Storage.getInstance().writeObject(appName + user + "-
offlineCommandsLocEnc", l_noAppt);
Initializing the Storage:
public void init(Object context) {
Preferences.setPreferencesLocation("EncryptedPreferences");
Storage.getInstance().deleteStorageFile(Cookie.STORAGE_NAME);
}
public class TrackLocation implements LocationListener {
private static TrackLocation instance = new TrackLocation();
private Location lastLocation;
private Timer time;
public static TrackLocation getInstance() {
return instance;
}
public void stopTracking() {
if (time != null) {
time.cancel();
}
time = null;
LocationManager.getLocationManager().setLocationListener(null);
}
public void startTracking() {
if (time != null) {
stopTracking();
}
if (Preferences.get("LocationTracking", true)) {
long delay = Server.instance.getLoctionPollingIntervalMillis();
LocationManager.getLocationManager().setLocationListener(this,
new LocationRequest(LocationRequest.PRIORITY_HIGH_ACCUARCY, delay));
time = new Timer();
time.schedule(new TimerTask() {
@Override
public void run() {
if (lastLocation != null) {
double lat = (double) lastLocation.getLatitude();
double lot = (double) lastLocation.getLongitude();
int successFlg = Server.instance.updateLocationInServer(lat, lot, System.currentTimeMillis(), true);
}
}
}, 30000, delay);
}
}
@Override
public void locationUpdated(Location location) {
lastLocation = location;
}
@Override
public void providerStateChanged(int newState) {
}
}
Error Log:
java.lang.ArrayIndexOutOfBoundsException:
at java.lang.System.arraycopy (Native Method)
at org.a.a.c.c.a (PaddedBufferedBlockCipher.java:203)
at com.codename1.e.a$a.write (EncryptedStorage.java:150)
at sun.nio.cs.StreamEncoder.writeBytes (StreamEncoder.java:221)
at sun.nio.cs.StreamEncoder.implWrite (StreamEncoder.java:282)
at sun.nio.cs.StreamEncoder.write (StreamEncoder.java:125)
at sun.nio.cs.StreamEncoder.write (StreamEncoder.java:135)
at java.io.OutputStreamWriter.write (OutputStreamWriter.java:220)
at java.io.PrintWriter.write (PrintWriter.java:456)
at java.io.PrintWriter.write (PrintWriter.java:473)
at java.io.PrintWriter.print (PrintWriter.java:603)
at java.io.PrintWriter.println (PrintWriter.java:756)
at java.lang.Throwable$WrappedPrintWriter.println (Throwable.java:755)
at java.lang.Throwable.printStackTrace (Throwable.java:650)
at java.lang.Throwable.printStackTrace (Throwable.java:712)
at com.codename1.impl.android.c.a (AndroidImplementation.java:5937)
at com.codename1.h.l.b (Log.java:347)
at com.codename1.h.l.a (Log.java:324)
at com.codename1.h.s.a (Storage.java:228)
at com.xxxx.xxxxxx.b.n.a (ServerImpl.java:1870)
at com.xxxx.xxxxxx.b.n.a (ServerImpl.java:1750)
at com.xxxx.xxxxxx.c.a$1.run (TrackLocation.java:52)
at java.util.TimerThread.mainLoop (Timer.java:555)
at java.util.TimerThread.run (Timer.java:505)
codenameone
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I see ArrayIndexOutOfBounds Exception thrown but there are three different methods in the following lines in the code.How would I read the log to find out which of the following lines the error being thrown at. Please advise.
ServerImpl.java:1870 or ServerImpl.java:1750 or TrackLocation.java:52
Code:
TrackLocation.java:52 -
int successFlg = Server.instance.updateLocationInServer(lat, lot,
System.currentTimeMillis(), true);
ServerImpl.java:1750 -
addOfflineCommand("locationService", lat, lot, System.currentTimeMillis());
ServerImpl.java:1870 -
Storage.getInstance().writeObject(appName + user + "-
offlineCommandsLocEnc", l_noAppt);
Initializing the Storage:
public void init(Object context) {
Preferences.setPreferencesLocation("EncryptedPreferences");
Storage.getInstance().deleteStorageFile(Cookie.STORAGE_NAME);
}
public class TrackLocation implements LocationListener {
private static TrackLocation instance = new TrackLocation();
private Location lastLocation;
private Timer time;
public static TrackLocation getInstance() {
return instance;
}
public void stopTracking() {
if (time != null) {
time.cancel();
}
time = null;
LocationManager.getLocationManager().setLocationListener(null);
}
public void startTracking() {
if (time != null) {
stopTracking();
}
if (Preferences.get("LocationTracking", true)) {
long delay = Server.instance.getLoctionPollingIntervalMillis();
LocationManager.getLocationManager().setLocationListener(this,
new LocationRequest(LocationRequest.PRIORITY_HIGH_ACCUARCY, delay));
time = new Timer();
time.schedule(new TimerTask() {
@Override
public void run() {
if (lastLocation != null) {
double lat = (double) lastLocation.getLatitude();
double lot = (double) lastLocation.getLongitude();
int successFlg = Server.instance.updateLocationInServer(lat, lot, System.currentTimeMillis(), true);
}
}
}, 30000, delay);
}
}
@Override
public void locationUpdated(Location location) {
lastLocation = location;
}
@Override
public void providerStateChanged(int newState) {
}
}
Error Log:
java.lang.ArrayIndexOutOfBoundsException:
at java.lang.System.arraycopy (Native Method)
at org.a.a.c.c.a (PaddedBufferedBlockCipher.java:203)
at com.codename1.e.a$a.write (EncryptedStorage.java:150)
at sun.nio.cs.StreamEncoder.writeBytes (StreamEncoder.java:221)
at sun.nio.cs.StreamEncoder.implWrite (StreamEncoder.java:282)
at sun.nio.cs.StreamEncoder.write (StreamEncoder.java:125)
at sun.nio.cs.StreamEncoder.write (StreamEncoder.java:135)
at java.io.OutputStreamWriter.write (OutputStreamWriter.java:220)
at java.io.PrintWriter.write (PrintWriter.java:456)
at java.io.PrintWriter.write (PrintWriter.java:473)
at java.io.PrintWriter.print (PrintWriter.java:603)
at java.io.PrintWriter.println (PrintWriter.java:756)
at java.lang.Throwable$WrappedPrintWriter.println (Throwable.java:755)
at java.lang.Throwable.printStackTrace (Throwable.java:650)
at java.lang.Throwable.printStackTrace (Throwable.java:712)
at com.codename1.impl.android.c.a (AndroidImplementation.java:5937)
at com.codename1.h.l.b (Log.java:347)
at com.codename1.h.l.a (Log.java:324)
at com.codename1.h.s.a (Storage.java:228)
at com.xxxx.xxxxxx.b.n.a (ServerImpl.java:1870)
at com.xxxx.xxxxxx.b.n.a (ServerImpl.java:1750)
at com.xxxx.xxxxxx.c.a$1.run (TrackLocation.java:52)
at java.util.TimerThread.mainLoop (Timer.java:555)
at java.util.TimerThread.run (Timer.java:505)
codenameone
I see ArrayIndexOutOfBounds Exception thrown but there are three different methods in the following lines in the code.How would I read the log to find out which of the following lines the error being thrown at. Please advise.
ServerImpl.java:1870 or ServerImpl.java:1750 or TrackLocation.java:52
Code:
TrackLocation.java:52 -
int successFlg = Server.instance.updateLocationInServer(lat, lot,
System.currentTimeMillis(), true);
ServerImpl.java:1750 -
addOfflineCommand("locationService", lat, lot, System.currentTimeMillis());
ServerImpl.java:1870 -
Storage.getInstance().writeObject(appName + user + "-
offlineCommandsLocEnc", l_noAppt);
Initializing the Storage:
public void init(Object context) {
Preferences.setPreferencesLocation("EncryptedPreferences");
Storage.getInstance().deleteStorageFile(Cookie.STORAGE_NAME);
}
public class TrackLocation implements LocationListener {
private static TrackLocation instance = new TrackLocation();
private Location lastLocation;
private Timer time;
public static TrackLocation getInstance() {
return instance;
}
public void stopTracking() {
if (time != null) {
time.cancel();
}
time = null;
LocationManager.getLocationManager().setLocationListener(null);
}
public void startTracking() {
if (time != null) {
stopTracking();
}
if (Preferences.get("LocationTracking", true)) {
long delay = Server.instance.getLoctionPollingIntervalMillis();
LocationManager.getLocationManager().setLocationListener(this,
new LocationRequest(LocationRequest.PRIORITY_HIGH_ACCUARCY, delay));
time = new Timer();
time.schedule(new TimerTask() {
@Override
public void run() {
if (lastLocation != null) {
double lat = (double) lastLocation.getLatitude();
double lot = (double) lastLocation.getLongitude();
int successFlg = Server.instance.updateLocationInServer(lat, lot, System.currentTimeMillis(), true);
}
}
}, 30000, delay);
}
}
@Override
public void locationUpdated(Location location) {
lastLocation = location;
}
@Override
public void providerStateChanged(int newState) {
}
}
Error Log:
java.lang.ArrayIndexOutOfBoundsException:
at java.lang.System.arraycopy (Native Method)
at org.a.a.c.c.a (PaddedBufferedBlockCipher.java:203)
at com.codename1.e.a$a.write (EncryptedStorage.java:150)
at sun.nio.cs.StreamEncoder.writeBytes (StreamEncoder.java:221)
at sun.nio.cs.StreamEncoder.implWrite (StreamEncoder.java:282)
at sun.nio.cs.StreamEncoder.write (StreamEncoder.java:125)
at sun.nio.cs.StreamEncoder.write (StreamEncoder.java:135)
at java.io.OutputStreamWriter.write (OutputStreamWriter.java:220)
at java.io.PrintWriter.write (PrintWriter.java:456)
at java.io.PrintWriter.write (PrintWriter.java:473)
at java.io.PrintWriter.print (PrintWriter.java:603)
at java.io.PrintWriter.println (PrintWriter.java:756)
at java.lang.Throwable$WrappedPrintWriter.println (Throwable.java:755)
at java.lang.Throwable.printStackTrace (Throwable.java:650)
at java.lang.Throwable.printStackTrace (Throwable.java:712)
at com.codename1.impl.android.c.a (AndroidImplementation.java:5937)
at com.codename1.h.l.b (Log.java:347)
at com.codename1.h.l.a (Log.java:324)
at com.codename1.h.s.a (Storage.java:228)
at com.xxxx.xxxxxx.b.n.a (ServerImpl.java:1870)
at com.xxxx.xxxxxx.b.n.a (ServerImpl.java:1750)
at com.xxxx.xxxxxx.c.a$1.run (TrackLocation.java:52)
at java.util.TimerThread.mainLoop (Timer.java:555)
at java.util.TimerThread.run (Timer.java:505)
codenameone
codenameone
edited Nov 15 at 0:21
asked Oct 19 at 22:27
LC1
42527
42527
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
0
down vote
This is an exception from writing to an encrypted storage. It's thrown by the cypher code. It's unclear why this failed or due to what action but it might be related to logging.
related logging means? what can i do to avoid this crash on the device. I'm attaching the writing to storage code. Please let me know if any thing causes this issue. I'm using the preference also.
– LC1
Oct 21 at 1:50
If I had to venture a guess it would be that you have background location turned on and encryption might be off when you get that specific event.
– Shai Almog
Oct 21 at 3:55
Hi Shai- is there any update on this. I still see the error being thrown and App gets crashed. Please advise. As you mentioned in this ticket you will add work around for this issue. stackoverflow.com/questions/52900596/…
– LC1
Nov 8 at 18:09
These are different exceptions with different reasons. This happens becauseTrackLocation
runs the timer with encryption misconfigured
– Shai Almog
Nov 9 at 5:06
shai...I have verified the code and i dot see anything wrong in my code. There should be something triggering internally. This happens once in a while and there could be some glitch or something in the library. Please advise.
– LC1
Nov 9 at 23:14
|
show 10 more comments
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
This is an exception from writing to an encrypted storage. It's thrown by the cypher code. It's unclear why this failed or due to what action but it might be related to logging.
related logging means? what can i do to avoid this crash on the device. I'm attaching the writing to storage code. Please let me know if any thing causes this issue. I'm using the preference also.
– LC1
Oct 21 at 1:50
If I had to venture a guess it would be that you have background location turned on and encryption might be off when you get that specific event.
– Shai Almog
Oct 21 at 3:55
Hi Shai- is there any update on this. I still see the error being thrown and App gets crashed. Please advise. As you mentioned in this ticket you will add work around for this issue. stackoverflow.com/questions/52900596/…
– LC1
Nov 8 at 18:09
These are different exceptions with different reasons. This happens becauseTrackLocation
runs the timer with encryption misconfigured
– Shai Almog
Nov 9 at 5:06
shai...I have verified the code and i dot see anything wrong in my code. There should be something triggering internally. This happens once in a while and there could be some glitch or something in the library. Please advise.
– LC1
Nov 9 at 23:14
|
show 10 more comments
up vote
0
down vote
This is an exception from writing to an encrypted storage. It's thrown by the cypher code. It's unclear why this failed or due to what action but it might be related to logging.
related logging means? what can i do to avoid this crash on the device. I'm attaching the writing to storage code. Please let me know if any thing causes this issue. I'm using the preference also.
– LC1
Oct 21 at 1:50
If I had to venture a guess it would be that you have background location turned on and encryption might be off when you get that specific event.
– Shai Almog
Oct 21 at 3:55
Hi Shai- is there any update on this. I still see the error being thrown and App gets crashed. Please advise. As you mentioned in this ticket you will add work around for this issue. stackoverflow.com/questions/52900596/…
– LC1
Nov 8 at 18:09
These are different exceptions with different reasons. This happens becauseTrackLocation
runs the timer with encryption misconfigured
– Shai Almog
Nov 9 at 5:06
shai...I have verified the code and i dot see anything wrong in my code. There should be something triggering internally. This happens once in a while and there could be some glitch or something in the library. Please advise.
– LC1
Nov 9 at 23:14
|
show 10 more comments
up vote
0
down vote
up vote
0
down vote
This is an exception from writing to an encrypted storage. It's thrown by the cypher code. It's unclear why this failed or due to what action but it might be related to logging.
This is an exception from writing to an encrypted storage. It's thrown by the cypher code. It's unclear why this failed or due to what action but it might be related to logging.
answered Oct 20 at 4:13
Shai Almog
38.8k52553
38.8k52553
related logging means? what can i do to avoid this crash on the device. I'm attaching the writing to storage code. Please let me know if any thing causes this issue. I'm using the preference also.
– LC1
Oct 21 at 1:50
If I had to venture a guess it would be that you have background location turned on and encryption might be off when you get that specific event.
– Shai Almog
Oct 21 at 3:55
Hi Shai- is there any update on this. I still see the error being thrown and App gets crashed. Please advise. As you mentioned in this ticket you will add work around for this issue. stackoverflow.com/questions/52900596/…
– LC1
Nov 8 at 18:09
These are different exceptions with different reasons. This happens becauseTrackLocation
runs the timer with encryption misconfigured
– Shai Almog
Nov 9 at 5:06
shai...I have verified the code and i dot see anything wrong in my code. There should be something triggering internally. This happens once in a while and there could be some glitch or something in the library. Please advise.
– LC1
Nov 9 at 23:14
|
show 10 more comments
related logging means? what can i do to avoid this crash on the device. I'm attaching the writing to storage code. Please let me know if any thing causes this issue. I'm using the preference also.
– LC1
Oct 21 at 1:50
If I had to venture a guess it would be that you have background location turned on and encryption might be off when you get that specific event.
– Shai Almog
Oct 21 at 3:55
Hi Shai- is there any update on this. I still see the error being thrown and App gets crashed. Please advise. As you mentioned in this ticket you will add work around for this issue. stackoverflow.com/questions/52900596/…
– LC1
Nov 8 at 18:09
These are different exceptions with different reasons. This happens becauseTrackLocation
runs the timer with encryption misconfigured
– Shai Almog
Nov 9 at 5:06
shai...I have verified the code and i dot see anything wrong in my code. There should be something triggering internally. This happens once in a while and there could be some glitch or something in the library. Please advise.
– LC1
Nov 9 at 23:14
related logging means? what can i do to avoid this crash on the device. I'm attaching the writing to storage code. Please let me know if any thing causes this issue. I'm using the preference also.
– LC1
Oct 21 at 1:50
related logging means? what can i do to avoid this crash on the device. I'm attaching the writing to storage code. Please let me know if any thing causes this issue. I'm using the preference also.
– LC1
Oct 21 at 1:50
If I had to venture a guess it would be that you have background location turned on and encryption might be off when you get that specific event.
– Shai Almog
Oct 21 at 3:55
If I had to venture a guess it would be that you have background location turned on and encryption might be off when you get that specific event.
– Shai Almog
Oct 21 at 3:55
Hi Shai- is there any update on this. I still see the error being thrown and App gets crashed. Please advise. As you mentioned in this ticket you will add work around for this issue. stackoverflow.com/questions/52900596/…
– LC1
Nov 8 at 18:09
Hi Shai- is there any update on this. I still see the error being thrown and App gets crashed. Please advise. As you mentioned in this ticket you will add work around for this issue. stackoverflow.com/questions/52900596/…
– LC1
Nov 8 at 18:09
These are different exceptions with different reasons. This happens because
TrackLocation
runs the timer with encryption misconfigured– Shai Almog
Nov 9 at 5:06
These are different exceptions with different reasons. This happens because
TrackLocation
runs the timer with encryption misconfigured– Shai Almog
Nov 9 at 5:06
shai...I have verified the code and i dot see anything wrong in my code. There should be something triggering internally. This happens once in a while and there could be some glitch or something in the library. Please advise.
– LC1
Nov 9 at 23:14
shai...I have verified the code and i dot see anything wrong in my code. There should be something triggering internally. This happens once in a while and there could be some glitch or something in the library. Please advise.
– LC1
Nov 9 at 23:14
|
show 10 more comments
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f52900649%2freading-the-crash-log%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown