Rockbox

  • Status Closed
  • Percent Complete
    100%
  • Task Type Bugs
  • Category User Interface → Simulator
  • Assigned To No-one
  • Operating System All players
  • Severity Low
  • Priority Very Low
  • Reported Version Daily build (which?)
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by Steve Bavin - 2007-06-01
Last edited by Steve Bavin - 2007-08-01

FS#7245 - Simulator crashes with a segfault in action.c

Recipe, for the H300 sim.
1) Clear settings. Restart sim.
2) Play a track from the filw browser.
3) Press SELECT to go from WPS to browser.
4) Prsss STOP to stop music playback

CRASH!
Program received signal SIGSEGV, Segmentation fault.
[Switching to thread 3996.0x4d0]
0×00401334 in get_action_worker (context=???, timeout=???, get_context_map=???) at action.c:110
110 button = button_get_w_tmo(timeout);

There’s not much backtrace to be seen:
(gdb) bt
#0 0×00401334 in get_action_worker (context=???, timeout=???, get_context_map=???)

  at action.c:110
Closed by  Steve Bavin
2007-08-01 09:12
Reason for closing:  Fixed
Steve Bavin commented on 2007-06-08 09:35

A little bit more info; the crash occurs when get_action_worker() calls button_get_w_tmo() in line 113.

Nils Wallménius commented on 2007-06-08 11:16

I tried to reproduce this but was unable to.

My h300 sim was built with gcc 4.1.2 for AMD64 and run in ubuntu.

I played an ogg vorbis file to test, did all the steps but no crash.

Steve Bavin commented on 2007-06-08 11:34

I’m using gcc 3.4.4 under Cygwin - 32-bit FWIW. Totally reproducible; just pressing STOP when music is playing but the WPS is not displayed will do it.

Jens Arnold commented on 2007-06-08 19:51

I tried to reproduce this bug on cygwin (gcc 3.4.4), debian-testing-x86 (gcc 4.1.2) and debian-unstable-amd64 (gcc 4.1.3 pre). The results are interesting:

- bug is reproducable on x86 sims, but not on amd64 sims (!)
- seems to be independent of audio file format (tried mp3 and ogg on x86 - just ogg on amd64 because of the known rockbox-libmad bug)
- seems to affect swcodec sims, but not hwcodec (tried h300 and sansa / archos recorder)

The backtrace on linux-x86, while not containing as many question marks, isn’t much more helpful:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1221067856 (LWP 24221)]
0×08049898 in get_action_worker (context=Cannot access memory at address 0×8 ) at action.c:113
113 button = button_get_w_tmo(timeout);
(gdb) bt
#0 0×08049898 in get_action_worker (context=Cannot access memory at address 0×8) at action.c:113
Cannot access memory at address 0×4 (gdb) print timeout
Cannot access memory at address 0xc

The “cannot access memory” messages are puzzling…

Jens Arnold commented on 2007-06-08 21:51

Some more findings:

It doesn’t always crash when stopping from outside the wps. So far I’ve been able to make it crash from the tree and the menu. Stopping from an audio control menu in a plugin (solitaire) wors fine.
It also doesn’t crash when single-stepping the audio stop action in gdb… :/

Steve Bavin commented on 2007-07-02 09:07

Possibly unrelated, but I can also reproduce a sim segfault by enabling/disabling crossfade during playback. I’ve attached my settings, just start playback then toggle crossfade between Always and Never.
Under GDB, this also gives no backtrace - just the following error:
Program received signal SIGSEGV, Segmentation fault.
[Switching to thread 1672.0x1d7c]
SDL_mutexP (mutex=???) at SDL_sysmutex.c:90
90 SDL_sysmutex.c: No such file or directory.

      in SDL_sysmutex.c
Steve Bavin commented on 2007-08-01 07:54

OK, I have done the binary chop on SVN revisions and this problem was introduced by the playback.c changes in r13317.

http://svn.rockbox.org/viewvc.cgi/trunk/apps/playback.c?r1=13117&r2=13317&pathrev=14094

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing