http://rpg.hamsterrepublic.com/bugzilla/show_bug.cgi?id=1011
Bug #: 1011
Summary: Game hangs when started in fullscreen from a terminal
under Linux with gfx_sdl
Classification: Unclassified
Product: OHRRPGCE
Version: Nightly WIP (Callipygous)
Platform: PC
OS/Version: Linux (Any)
Status: NEW
Severity: normal
Priority: P3
Component: backend:gfx_sdl
AssignedTo: [email protected]
ReportedBy: [email protected]
I'm marking this bug as gfx_sdl because I can't reproduce it with gfx_fb, but I
think it's a bug in the FB rtlib. Also, I can't reproduce it with FB 0.90.1,
but only with FB 0.23, so it's likely fixed already. We're not ready to switch
to FB 0.90 yet though.
When I launch Game in fullscreen from a terminal emulator (eg "ohrrpgce-game
-gfx sdl -f") maybe half the time it hangs. Switching to a linux terminal and
attaching gdb I always (tried maybe 15 times) see it's stuck in the same place:
(gdb) bt
#0 0xf7240841 in read () from /lib/libc.so.6
#1 0xf71dccc3 in __GI__IO_file_underflow () from /lib/libc.so.6
#2 0xf71ddcd9 in __GI__IO_default_uflow () from /lib/libc.so.6
#3 0xf71dda4a in __uflow () from /lib/libc.so.6
#4 0xf71c0d94 in __GI__IO_vfscanf () from /lib/libc.so.6
#5 0xf71cdb04 in __isoc99_fscanf () from /lib/libc.so.6
#6 0x082b6737 in console_resize ()
#7 <signal handler called>
#8 0xf7211dff in waitpid () from /lib/libc.so.6
#9 0xf71a86fe in do_system () from /lib/libc.so.6
#10 0xf71a8b05 in system () from /lib/libc.so.6
#11 0xf77166cb in system () from /lib/libpthread.so.0
#12 0x082b6045 in fb_Shell ()
#13 0x0805848b in ISDIR (SDIR=...) at util.bas:1556
#14 0x081ef799 in COPYLUMP (PACKAGE=..., LUMP=..., DEST=...,
IGNOREMISSING=<error reading variable>) at lumpfile.bas:937
#15 0x0823fa78 in BROWSE_ADD_FILES (WILDCARD=..., FILETYPE=<error reading
variable>, BR=..., TREE=...) at browse.bas:452
#16 0x0824162d in BUILD_LISTING (TREE=..., BR=...) at browse.bas:694
#17 0x0823cad9 in BROWSE (SPECIAL=<error reading variable>, DEFAULT=...,
FMASK=..., TMP=..., NEEDF=<error reading variable>,
HELPKEY=...) at browse.bas:143
#18 0x080884a3 in main (__FB_ARGC__=<error reading variable>,
__FB_ARGV__=<error reading variable>) at game.bas:432
fscanf isn't actually called from console_resize (which is the SIGWINCH handler
in FB's rtlib), but from fb_hTermQuery which has been inlined. fscanf is stuck
waiting for more data from stdin. fb_hTermQuery is trying to read an escape
sequence to get the new terminal size; it's making the bad assumption that
there is data to read. SIGWINCH signals a terminal ("window") size change. This
is guarded by #ifdef HOST_LINUX in the rtlib.
The hang doesn't happen in Custom because Custom doesn't do SHELL calls
immediately after starting up, which seems to be the trigger. I suspect it
doesn't happen with gfx_fb because of internal ties between rtlib and fbgfx. It
only happens when running in fullscreen, at a low zoom level like 2, when
started from a terminal, because this causes SDL to mode switch to 640x400,
which causes the terminal emulator window to change in size, generating a
SIGWINCH just as Game is doing a SHELL call. Sure enough, launching Game using
KDE's alt+F2 shortcut, or resizing the terminal editor window really small,
don't trigger the problem, nor does starting in a window and then
fullscreening.
--
Configure bugmail:
http://rpg.hamsterrepublic.com/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Ohrrpgce mailing list
[email protected]
http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org