[Scummvm-tracker] [ScummVM :: Bugs] #12944: Starship Titanic: asking gossipy DeskBot to continue yields "I don't understand" responses or crashes the game

ScummVM :: Bugs trac at scummvm.org
Mon Sep 20 05:19:22 UTC 2021


#12944: Starship Titanic: asking gossipy DeskBot to continue yields "I don't
understand" responses or crashes the game
-----------------------------+-------------------------------
Reporter:  CahootsMalone     |       Owner:  (none)
    Type:  defect            |      Status:  new
Priority:  normal            |   Component:  Engine: Titanic
 Version:                    |  Resolution:
Keywords:  Starship Titanic  |        Game:  Starship Titanic
-----------------------------+-------------------------------
Comment (by eriktorbjorn):

 I can reproduce this, but only if I compile with optimizations. Without,
 it doesn't even trigger Valgrind warnings. (I don't want to debug further
 with Valgrind, because it's ''horrifyingly'' slow on my computer, even by
 Valgrind standards.)

 I'm using GCC 10.3 (Debian 10.3.0-10), and it crashes with -O2 but not
 with -Og. So that's annoying since -Og would be better suited for
 debugging.

 With -O2, I get the following backtrace:

 {{{
 #0  Titanic::TTconcept::findByWordClass(Titanic::WordClass)
     (this=this at entry=0x0, wordClass=wordClass at entry=Titanic::WC_ACTION)
     at engines/titanic/true_talk/tt_concept.cpp:288
 #1  0x00005555559cc485 in
 Titanic::TTparser::considerRequests(Titanic::TTword*)
     (this=this at entry=0x555557206bf0, word=0x55555928acb0)
     at engines/titanic/true_talk/tt_parser.cpp:1000
 #2  0x00005555559cd11b in Titanic::TTparser::checkForAction()
     (this=this at entry=0x555557206bf0)
     at engines/titanic/true_talk/tt_parser.cpp:1469
 #3  0x00005555559cd72b in
 Titanic::TTparser::findFrames(Titanic::TTsentence*)
     (this=this at entry=0x555557206bf0,
 sentence=sentence at entry=0x5555593c86a0)
     at engines/titanic/true_talk/tt_parser.cpp:540
 #4  0x00005555559c4a6b in
 Titanic::CScriptHandler::processInput(Titanic::TTroomScript*,
 Titanic::TTnpcScript*, Titanic::TTstring const&)
     (this=this at entry=0x555557206be0,
 roomScript=roomScript at entry=0x55555721f830,
 npcScript=npcScript at entry=0x55555779edc0, line=...)
     at engines/titanic/true_talk/script_handler.cpp:96
 #5  0x0000555555984ad7 in
 Titanic::CTrueTalkManager::processInput(Titanic::CTrueTalkNPC*,
 Titanic::CTextInputMsg*, Titanic::CViewItem*)
     (this=0x5555573dea10, npc=npc at entry=0x555556fbda40,
 msg=0x7fffffffd5a0,
     msg at entry=0x7fffffffd6e0, view=view at entry=0x555558bd00f0)
     at engines/titanic/true_talk/true_talk_manager.cpp:335
 #6  0x0000555555945e94 in
 Titanic::CTrueTalkNPC::processInput(Titanic::CTextInputMsg*,
 Titanic::CViewItem*)
     (view=0x555558bd00f0, msg=0x7fffffffd6e0, this=0x555556fbda40)
     at engines/titanic/npcs/true_talk_npc.cpp:236
 #7  Titanic::CTrueTalkNPC::TextInputMsg(Titanic::CTextInputMsg*)
     (this=<optimized out>, msg=0x7fffffffd6e0)
     at engines/titanic/npcs/true_talk_npc.cpp:83
 #8  0x000055555592f8a9 in Titanic::CMessage::execute(Titanic::CTreeItem*,
 Titanic::ClassDef const*, int)
     (this=this at entry=0x7fffffffd6e0, target=0x555556fbda40,
 classDef=classDef at entry=0x0, flags=flags at entry=3) at
 engines/titanic/messages/messages.cpp:60
 #9  0x000055555592f91a in Titanic::CMessage::execute(Titanic::CTreeItem*,
 Titanic::ClassDef const*, int)
     (this=this at entry=0x7fffffffd6e0, target=<optimized out>,
 classDef=classDef at entry=0x0, flags=flags at entry=3) at
 engines/titanic/messages/messages.cpp:49
 #10 0x000055555594aaf7 in
 Titanic::CPetConversations::textLineEntered(Titanic::CString const&)
 (this=this at entry=0x555558dc8658, textLine=...)
     at engines/titanic/pet_control/pet_conversations.cpp:507
 #11 0x000055555594adcc in
 Titanic::CPetConversations::handleKey(Common::KeyState const&)Python
 Exception <class 'gdb.error'> Dwarf Error: Cannot find DIE at 0x0
 referenced in module /home/d91tan/src/CVS/scummvm-2.3+hack/scummvm:

     (keyState=#12
 Titanic::CPetConversations::KeyCharMsg(Titanic::CKeyCharMsg*)
     (this=0x555558dc8658, msg=<optimized out>)
     at engines/titanic/pet_control/pet_conversations.cpp:224
 #13 0x0000555555946d09 in
 Titanic::CPetControl::KeyCharMsg(Titanic::CKeyCharMsg*)
 (this=0x555558dc84f0, msg=0x7fffffffd8d0)
     at engines/titanic/pet_control/pet_control.cpp:339
 #14 0x000055555592f8a9 in Titanic::CMessage::execute(Titanic::CTreeItem*,
 Titanic::ClassDef const*, int)
     (this=this at entry=0x7fffffffd8d0, target=0x555558dc84f0,
 classDef=classDef at entry=0x0, flags=flags at entry=2) at
 engines/titanic/messages/messages.cpp:60
 #15 0x000055555592f91a in Titanic::CMessage::execute(Titanic::CTreeItem*,
 Titanic::ClassDef const*, int)
     (this=this at entry=0x7fffffffd8d0, target=<optimized out>,
 classDef=classDef at entry=0x0, flags=flags at entry=2) at
 engines/titanic/messages/messages.cpp:49
 #16 0x0000555555991ac2 in
 Titanic::CInputHandler::dispatchMessage(Titanic::CMessage*)
 (this=0x5555573ed1b0, msg=0x7fffffffd8d0)
     at engines/titanic/input_handler.cpp:154
 #17 0x0000555555991c73 in
 Titanic::CInputHandler::processMessage(Titanic::CMessage*)
 (this=0x5555573ed1b0, msg=0x7fffffffd8d0)
     at engines/titanic/input_handler.cpp:84
 #18 0x0000555555991f8d in
 Titanic::CInputHandler::handleMessage(Titanic::CMessage&, bool)
 (this=<optimized out>, msg=..., respectLock=respectLock at entry=true)
     at engines/titanic/input_handler.cpp:72
 #19 0x00005555559923c8 in
 Titanic::CInputTranslator::keyDown(Common::KeyState const&)
 (this=0x5555573ed1e0, keyState=...)
     at engines/titanic/input_translator.cpp:91
 #20 0x0000555555992565 in
 Titanic::CMainGameWindow::keyDown(Common::KeyState) (this=0x555557a278f0,
 keyState=...)
     at engines/titanic/main_game_window.cpp:363
 #21 0x000055555598f1d8 in Titanic::Events::pollEvents()
 (this=0x555557773dc0)
     at engines/titanic/events.cpp:95
 #22 0x000055555598f3bd in Titanic::Events::pollEventsAndWait()
     (this=<optimized out>) at engines/titanic/events.cpp:112
 #23 0x00005555558aab6c in Titanic::TitanicEngine::run()
 (this=0x555557640760)
     at engines/titanic/titanic.cpp:146
 #24 0x000055555588def7 in runGame(Plugin const*, Plugin const*, OSystem&,
 Common::String const&)
     (plugin=plugin at entry=0x555556465000, enginePlugin=0x7fffffffdc38,
     enginePlugin at entry=0x5555566a0ab0, system=..., debugLevels=...)
     at base/main.cpp:311
 #25 0x00005555558903a5 in scummvm_main(int, char const* const*)
     (argc=<optimized out>, argv=<optimized out>) at base/main.cpp:616
 #26 0x0000555555835104 in main(int, char**) (argc=1, argv=0x7fffffffe638)
     at backends/platform/sdl/posix/posix-main.cpp:45
 }}}

 (Yes, the backtrace really did triger some Python exception. Oh well,
 hopefully it's reliable enough.)

 Apparently, _conceptP was NULL when considerRequests() tried to call
 findByWordClass() in it.
-- 
Ticket URL: <https://bugs.scummvm.org/ticket/12944#comment:2>
ScummVM :: Bugs <https://bugs.scummvm.org>
ScummVM


More information about the Scummvm-tracker mailing list