Hi

I'm contributing to a project that retrieves real-time data about
public transportation in Oslo. And we have a bug that I'm unable to
track down.

The flow of the application is something like this:
1. Display favorite stops (either in an Activity or from a LiveFolder)
2. User chooses a stop
3. The departures for that stop is retrieved from the web, parsed with
a SAX parser and then displayed to the user
4. At this point the user either press "home" to exit the Activity or
"back" to return to the favorite stops view
5. Either way, if the user chooses more stops without exiting the
entire application - it will sooner or later crash right before it
finishes loading the departures, or right after displaying them

I've pasted the log below, and was just wondering if it's possible to
confirm my suspicion that it crashes because it ran out of memory?

And if it is because of the memory, are there any immediate
improvements I could make to avoid this?

The code for the application can be retrieved from gitorious:
http://gitorious.org/trafikanten/trafikanten-android if anybody would
care to look at it. I suspect that it's because of something that the
DepartureView does, but that is just speculation.

Thanks in advance for any help!

-- Marius

This is a log where it crashes the third time I try to load
departures:
01-27 12:21:22.540: DEBUG/dalvikvm(9287): GC freed 3322 objects /
190256 bytes in 119ms
01-27 12:21:23.450: INFO/ActivityManager(57): Starting activity:
Intent { act=android.intent.action.VIEW dat=sanntid://no.shortcut/
3010032 cmp=no.shortcut/.DepartureView }
01-27 12:21:23.480: WARN/UsageStats(57): Failed to persist new stats
01-27 12:21:23.730: DEBUG/dalvikvm(10641): GC freed 1165 objects /
83640 bytes in 102ms
01-27 12:21:23.901: DEBUG/DepartureView(10641): OnCreate
01-27 12:21:23.950: DEBUG/DepartureView(10641): OnResume.
01-27 12:21:23.970: DEBUG/Stop(10641): 
http://d42.no/trafikanten/bus/request?DISID=SN$3010032
01-27 12:21:24.480: DEBUG/Stop(10641): Retrieving departures and
parsing
01-27 12:21:24.541: DEBUG/DepartureXmlHandler(10641): Starting
document parsing
01-27 12:21:24.550: INFO/ActivityManager(57): Displayed activity
no.shortcut/.DepartureView: 744 ms (total 744 ms)
01-27 12:21:24.561: WARN/UsageStats(57): Failed to persist new stats
01-27 12:21:24.621: DEBUG/DepXmlHandler(10641): Found 0 departures.
01-27 12:21:25.210: DEBUG/Stop(10641): Retrieving departures and
parsing
01-27 12:21:25.220: DEBUG/DepartureXmlHandler(10641): Starting
document parsing
01-27 12:21:25.410: DEBUG/dalvikvm(10641): GC freed 3660 objects /
243448 bytes in 104ms
01-27 12:21:26.750: DEBUG/dalvikvm(10641): GC freed 11402 objects /
561040 bytes in 124ms
01-27 12:21:27.760: DEBUG/DepXmlHandler(10641): Found 97 departures.
01-27 12:21:27.770: DEBUG/DepartureView(10641): Posting results.
01-27 12:21:27.780: DEBUG/DepartureView(10641): Inserting departures
01-27 12:21:28.130: DEBUG/dalvikvm(10641): GC freed 9489 objects /
499544 bytes in 114ms
01-27 12:21:32.400: WARN/KeyCharacterMap(10641): No keyboard for id 0
01-27 12:21:32.400: WARN/KeyCharacterMap(10641): Using default
keymap: /system/usr/keychars/qwerty.kcm.bin
01-27 12:21:32.420: WARN/UsageStats(57): Failed to persist new stats
01-27 12:21:32.510: DEBUG/FavoriteStops(10641): Starting activity.
01-27 12:21:32.950: DEBUG/DepartureView(10641): DESTROY DEPVIEW!
01-27 12:21:34.290: INFO/ActivityManager(57): Starting activity:
Intent { act=android.intent.action.VIEW dat=sanntid://no.shortcut/
3010626 cmp=no.shortcut/.DepartureView }
01-27 12:21:34.300: WARN/UsageStats(57): Failed to persist new stats
01-27 12:21:34.571: DEBUG/DepartureView(10641): OnCreate
01-27 12:21:34.601: DEBUG/DepartureView(10641): OnResume.
01-27 12:21:34.621: DEBUG/Stop(10641): 
http://d42.no/trafikanten/bus/request?DISID=SN$3010626
01-27 12:21:34.740: DEBUG/Stop(10641): Retrieving departures and
parsing
01-27 12:21:34.750: DEBUG/DepartureXmlHandler(10641): Starting
document parsing
01-27 12:21:34.770: DEBUG/DepXmlHandler(10641): Found 0 departures.
01-27 12:21:35.110: DEBUG/Stop(10641): Retrieving departures and
parsing
01-27 12:21:35.110: DEBUG/DepartureXmlHandler(10641): Starting
document parsing
01-27 12:21:35.140: INFO/ActivityManager(57): Displayed activity
no.shortcut/.DepartureView: 654 ms (total 654 ms)
01-27 12:21:35.140: WARN/UsageStats(57): Failed to persist new stats
01-27 12:21:35.551: DEBUG/DepXmlHandler(10641): Found 17 departures.
01-27 12:21:35.551: DEBUG/DepartureView(10641): Posting results.
01-27 12:21:35.561: DEBUG/DepartureView(10641): Inserting departures
01-27 12:21:39.260: WARN/UsageStats(57): Failed to persist new stats
01-27 12:21:39.340: DEBUG/FavoriteStops(10641): Starting activity.
01-27 12:21:39.770: DEBUG/DepartureView(10641): DESTROY DEPVIEW!
01-27 12:21:45.670: INFO/ActivityManager(57): Starting activity:
Intent { act=android.intent.action.VIEW dat=sanntid://no.shortcut/
3010031 cmp=no.shortcut/.DepartureView }
01-27 12:21:45.713: WARN/UsageStats(57): Failed to persist new stats
01-27 12:21:46.030: DEBUG/DepartureView(10641): OnCreate
01-27 12:21:46.190: DEBUG/dalvikvm(10641): GC freed 6950 objects /
377920 bytes in 135ms
01-27 12:21:46.200: DEBUG/DepartureView(10641): OnResume.
01-27 12:21:46.220: DEBUG/Stop(10641): 
http://d42.no/trafikanten/bus/request?DISID=SN$3010031
01-27 12:21:46.380: INFO/DEBUG(28): *** *** *** *** *** *** *** ***
*** *** *** *** *** *** *** ***
01-27 12:21:46.410: INFO/DEBUG(28): Build fingerprint: 'generic/
google_sdk/generic/:2.0/ECLAIR/17704:eng/test-keys'
01-27 12:21:46.420: INFO/DEBUG(28): pid: 10641, tid: 10642  >>>
no.shortcut <<<
01-27 12:21:46.430: INFO/DEBUG(28): signal 11 (SIGSEGV), fault addr
00000004
01-27 12:21:46.430: INFO/DEBUG(28):  r0 00000004  r1 40024038  r2
00000004  r3 426ccfd4
01-27 12:21:46.440: DEBUG/Stop(10641): Retrieving departures and
parsing
01-27 12:21:46.450: DEBUG/DepartureXmlHandler(10641): Starting
document parsing
01-27 12:21:46.480: INFO/DEBUG(28):  r4 00000000  r5 00000000  r6
4227d9c1  r7 426ccfa8
01-27 12:21:46.480: INFO/DEBUG(28):  r8 100ffcd8  r9 426ccfa0  10
426ccf8c  fp 0011c558
01-27 12:21:46.480: INFO/DEBUG(28):  ip ad36023c  sp 100ffcc0  lr
ad3281d3  pc afb043d8  cpsr 00000010
01-27 12:21:46.830: INFO/ActivityManager(57): Displayed activity
no.shortcut/.DepartureView: 881 ms (total 881 ms)
01-27 12:21:46.830: WARN/UsageStats(57): Failed to persist new stats
01-27 12:21:47.170: INFO/DEBUG(28):          #00  pc 000043d8  /system/
lib/libcutils.so
01-27 12:21:47.190: INFO/DEBUG(28):          #01  lr ad3281d3  /system/
lib/libandroid_runtime.so
01-27 12:21:47.190: INFO/DEBUG(28): code around pc:
01-27 12:21:47.200: INFO/DEBUG(28): afb043c8 e8bd4010 e12fff1e
e92d4010 e1a02000
01-27 12:21:47.220: INFO/DEBUG(28): afb043d8 e5920000 e3e03a0f
e28fe004 e2401001
01-27 12:21:47.220: INFO/DEBUG(28): afb043e8 e243f03f 3afffff9
e2810001 e8bd4010
01-27 12:21:47.230: INFO/DEBUG(28): code around lr:
01-27 12:21:47.240: INFO/DEBUG(28): ad3281c0 fffee138 00005900
1c04b510 f7ef3004
01-27 12:21:47.240: INFO/DEBUG(28): ad3281d0 2801ef12 6060d104
68436820 47981c20
01-27 12:21:47.240: INFO/DEBUG(28): ad3281e0 46c0bd10 4c1ab5f0
1c05b083 1c1e447c
01-27 12:21:47.250: INFO/DEBUG(28): stack:
01-27 12:21:47.260: INFO/DEBUG(28):     100ffc80  00002bb4
01-27 12:21:47.270: INFO/DEBUG(28):     100ffc84  000000dc
01-27 12:21:47.280: INFO/DEBUG(28):     100ffc88  100ffcd8
01-27 12:21:47.280: INFO/DEBUG(28):     100ffc8c  afe0b37b  /system/
lib/libc.so
01-27 12:21:47.280: INFO/DEBUG(28):     100ffc90  00301068  [heap]
01-27 12:21:47.280: INFO/DEBUG(28):     100ffc94  afe3b9bc
01-27 12:21:47.291: INFO/DEBUG(28):     100ffc98  421e0778  /data/
dalvik-cache/sys...@framework@framework....@classes.dex
01-27 12:21:47.291: INFO/DEBUG(28):     100ffc9c  421e0778  /data/
dalvik-cache/sys...@framework@framework....@classes.dex
01-27 12:21:47.330: INFO/DEBUG(28):     100ffca0  00000001
01-27 12:21:47.330: INFO/DEBUG(28):     100ffca4  afe3bae8
01-27 12:21:47.330: INFO/DEBUG(28):     100ffca8  00000002
01-27 12:21:47.330: INFO/DEBUG(28):     100ffcac  410ad3c4  /dev/
ashmem/dalvik-LinearAlloc (deleted)
01-27 12:21:47.330: INFO/DEBUG(28):     100ffcb0  100ffd20
01-27 12:21:47.330: INFO/DEBUG(28):     100ffcb4  000002a4
01-27 12:21:47.380: INFO/DEBUG(28):     100ffcb8  df002777
01-27 12:21:47.380: INFO/DEBUG(28):     100ffcbc  e3a070ad
01-27 12:21:47.380: INFO/DEBUG(28): #00 100ffcc0  00000000
01-27 12:21:47.380: INFO/DEBUG(28):     100ffcc4  ad3281d3  /system/
lib/libandroid_runtime.so
01-27 12:21:47.380: INFO/DEBUG(28):     100ffcc8  100ffcf8
01-27 12:21:47.380: INFO/DEBUG(28):     100ffccc  ad3460d1  /system/
lib/libandroid_runtime.so
01-27 12:21:47.380: INFO/DEBUG(28):     100ffcd0  100ffcf8
01-27 12:21:47.380: INFO/DEBUG(28):     100ffcd4  ad00f1f8  /system/
lib/libdvm.so
01-27 12:21:47.380: INFO/DEBUG(28):     100ffcd8  410ad3c4  /dev/
ashmem/dalvik-LinearAlloc (deleted)
01-27 12:21:47.380: INFO/DEBUG(28):     100ffcdc  00132ac8  [heap]
01-27 12:21:47.390: INFO/DEBUG(28):     100ffce0  4227d9c1  /data/
dalvik-cache/sys...@framework@framework....@classes.dex
01-27 12:21:47.405: INFO/DEBUG(28):     100ffce4  100ffd88
01-27 12:21:47.405: INFO/DEBUG(28):     100ffce8  ad00f380  /system/
lib/libdvm.so
01-27 12:21:47.405: INFO/DEBUG(28):     100ffcec  00132ac8  [heap]
01-27 12:21:47.410: INFO/DEBUG(28):     100ffcf0  100ffcf8
01-27 12:21:47.541: INFO/DEBUG(28):     100ffcf4  ad037f4b  /system/
lib/libdvm.so
01-27 12:21:47.550: INFO/DEBUG(28):     100ffcf8  426ccfa0
01-27 12:21:47.550: INFO/DEBUG(28):     100ffcfc  4227d9c1  /data/
dalvik-cache/sys...@framework@framework....@classes.dex
01-27 12:21:47.561: INFO/DEBUG(28):     100ffd00  ad3460c9  /system/
lib/libandroid_runtime.so
01-27 12:21:47.561: INFO/DEBUG(28):     100ffd04  100ffd88
01-27 12:21:49.561: DEBUG/DepXmlHandler(10641): Found 48 departures.
01-27 12:21:49.611: DEBUG/Stop(10641): Retrieving departures and
parsing
01-27 12:21:49.621: DEBUG/DepartureXmlHandler(10641): Starting
document parsing
01-27 12:21:49.654: DEBUG/DepXmlHandler(10641): Found 0 departures.
01-27 12:21:49.680: DEBUG/DepartureView(10641): Posting results.
01-27 12:21:49.680: DEBUG/DepartureView(10641): Inserting departures
01-27 12:21:50.080: DEBUG/dalvikvm(10641): GC freed 10948 objects /
577664 bytes in 256ms
01-27 12:21:50.260: DEBUG/Zygote(30): Process 10641 terminated by
signal (11)
01-27 12:21:50.290: INFO/ActivityManager(57): Process no.shortcut (pid
10641) has died.
01-27 12:21:50.320: INFO/WindowManager(57): WIN DEATH: Window{43c2a298
no.shortcut/no.shortcut.FavoriteStopsActivity paused=false}
01-27 12:21:50.320: INFO/WindowManager(57): WIN DEATH: Window{43b9cdd0
no.shortcut/no.shortcut.DepartureView paused=false}
01-27 12:21:50.480: INFO/ActivityManager(57): Start proc no.shortcut
for activity no.shortcut/.FavoriteStopsActivity: pid=10670 uid=10023
gids={3003, 1015}
01-27 12:21:50.800: DEBUG/ddm-heap(10670): Got feature list request
01-27 12:21:51.000: WARN/UsageStats(57): Something wrong here, didn't
expect no.shortcut to be resumed

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to