Opened 4 years ago

Closed 4 years ago

#11351 closed defect (invalid)

3DS: Attempting to apply GUI themes besides the default one causes a stack overflow

Reported by: BallM4788 Owned by: BallM4788
Priority: normal Component: Ports
Version: Keywords: 3DS
Cc: Game:


Port: 3DS
Hardware: New Nintendo 3DS (North American Black Friday 2016 Edition [not XL])

Last version without bug: 2.1.0
First version with bug: 2.1.1
Commit in which bug was introduced: f22e078

Steps to Reproduce Bug:
1) Open ScummVM
2) Press 'Options...' button.
3) Scroll to and select 'Misc' tab.
4) Press 'Theme:' button.
5) Select 'ScummVM Modern Theme' or 'ScummVM Modern Theme Remastered' ('ScummVM Classic Theme is the same as the default theme).
6) Press 'Choose' button.
7) Press 'Apply' or 'OK' button. System crashes and the Luma crash screen appears. The stack dump that displays in the bottom screen is empty, indicating a stack overflow.

The file sizes for each of the ScummVM themes (as of b4fd25a) is as follows:

  • 160.4 kB
  • 290.5 kB
  • 288.5 kB

The 3DS's memory stack is 256kB, so the classic theme is the only one that works. 3DS releases of ScummVM prior to 2.1.1 applied themes differently, most notably requiring support files to be located separately on the SD card rather than be embedded within the ScummVM application itself.

Attachments (2)

failed backtrace.txt (171 bytes ) - added by BallM4788 4 years ago.
crash_dump_00000059.dmp (196 bytes ) - added by BallM4788 4 years ago.

Download all attachments as: .zip

Change History (5)

by BallM4788, 4 years ago

Attachment: failed backtrace.txt added

by BallM4788, 4 years ago

Attachment: crash_dump_00000059.dmp added

comment:1 by bgK, 4 years ago


Switching themes works fine for me. Incidentally, the commit you reference was mostly motivated by the need to have themes working without having to copy files to the SD card.

Does the issue occur with the release build from the ScummVM downloads page or with the builds from buildbot?
If it happens only with your own builds, you might want to check the version of FreeType you are using. We require an old version, as newer versions allocate too much on the stack. I use version 2.6.5.

Last edited 4 years ago by bgK (previous) (diff)

comment:2 by BallM4788, 4 years ago

Just tried the latest dev build from buildbot, it works fine. I had my freetype installed through dkp-pacman, and sure enough it builds from 2.9. Can I ask what you did to install 2.6.5?

EDIT: Nevermind, I think I got it.

EDIT 2: Yep, that was definitely the problem.

Last edited 4 years ago by BallM4788 (previous) (diff)

comment:3 by BallM4788, 4 years ago

Owner: set to BallM4788
Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.