MantisBT

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0001001VCMIGUI - Town screenpublic2012-06-13 19:042012-07-20 17:38
Reporterdouggie_m 
Assigned ToIvan 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionno change required 
PlatformPowerPCOSGNU/LinuxOS Version
Product Version 
Target VersionFixed in Version 
Summary0001001: Crash (failed assertion) on attempt to merge armies by moving hero from visiting to garrison
Descriptionvcmiserver: CGameHandler.cpp:2687: void CGameHandler::moveArmy(const CArmedInstance*, const CArmedInstance*, bool): Assertion `src->canBeMergedWith(*dst, allowMerging)' failed.
Aborted
Error: server failed to close correctly or crashed!
Lost connection to server, ending listening thread!
read: End of file
Something wrong, lost connection while game is still ongoing...
terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::system::system_error> >'
  what(): read: End of file
Aborted
Steps To ReproduceBuy a lot of creatures in town, bring hero to that town, and try to move hero from visiting position to garrison.
The result: in the case when armies cannot be combined, server crashes with a message "Assertion `src->canBeMergedWith(*dst, allowMerging)' failed."
Additional InformationAs I remember, original game was silent in the case when garrison and hero armies were "unmergable", so this assert is just not needed. It just does suddenly interrupt a game.
TagsNo tags attached.
Attached Files? file icon settings.json [^] (315 bytes) 2012-06-16 17:27
bz2 file icon test2.savegame.tar.bz2 [^] (153,216 bytes) 2012-06-16 17:44
bz2 file icon test34.savegame.tar.bz2 [^] (153,556 bytes) 2012-06-16 17:57

- Relationships

-  Notes
(0002671)
Warmonger (administrator)
2012-06-13 19:21

Well, the problem can be more general (not tested yet).

If game handler fails assertion, it means that the interface allowed to merge armies in first place, which should not happen. Such problem often means desync or unhandled case - merging armies is complicated task.
That's the general logic behind assertions.
(0002672)
Ivan (developer)
2012-06-13 19:30

Bug in client should not cause crash in game handler in first place.

But this is definitely does not looks like "remove assert and be happy" case.
(0002681)
douggie_m (reporter)
2012-06-14 17:08

> But this is definitely does not look like "remove assert and be happy" case.

Okay, add some console output, if that would help :)
(0002694)
Ivan (developer)
2012-06-15 16:00

Hi. Can you make screenshot of armies that will cause this crash? Everything looks fine for me.
(0002695)
douggie_m (reporter)
2012-06-15 21:52

I currently got on ending a turn:

----------------------------------------
Player 7 ends turn
Player 7 ended turn
System message: Game has been saved as Autosave_1
const TerrainTile* CGameInfoCallback::getTile(int3, bool) const: -1 -1 -1 is not visible!
Lost connection to server, ending listening thread!
boost::too_many_args: format-string referred to less arguments than were passed
Something wrong, lost connection while game is still ongoing...
terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::io::too_many_args> >'
  what(): boost::too_many_args: format-string referred to less arguments than were passed
Aborted
----------------------------------------

And also — the impossibility to launch game under non-root privs (under root everything is okay, except that "const: -1 -1 -1 is not visible!"):

----------------------------------------
$ ./usr/bin/vcmiclient
Starting...
Creating console and logfile: 0
Loading settings: 20
VCMI 0.89b (client)
Error: SDL says that 0x0 resolution is not available!
        Initializing screen: 160
        Initializing video: 0
        Initializing minors: 0
        Initializing sound: 20
Initializing screen and sound handling: 20
Loading .lod files: 160
        General text handler: 20
        Hero handler: 80
        Artifact handler: 0
Segmentation fault
----------------------------------------

----------------------------------------
(gdb) run
Starting program: /home/username/Development/VCMI/vcmi-svn/__dest/usr/bin/vcmiclient
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/powerpc-linux-gnu/libthread_db.so.1".
Starting...
[New Thread 0xf7f9a450 (LWP 20085)]
Creating console and logfile: 0
Loading settings: 40
VCMI 0.89b (client)
[New Thread 0xf779a450 (LWP 20086)]
[New Thread 0xf2d3a450 (LWP 20087)]
[Thread 0xf2d3a450 (LWP 20087) exited]
Error: SDL says that 0x0 resolution is not available!
        Initializing screen: 140
        Initializing video: 0
[New Thread 0xf2d3a450 (LWP 20088)]
        Initializing minors: 0
[New Thread 0xf58ff450 (LWP 20089)]
        Initializing sound: 20
Initializing screen and sound handling: 20

Program received signal SIGSEGV, Segmentation fault.
0x0e298fc8 in SDL_CreateYUVOverlay () from /usr/lib/powerpc-linux-gnu/libSDL-1.2.so.0
(gdb) bt
#0 0x0e298fc8 in SDL_CreateYUVOverlay () from /usr/lib/powerpc-linux-gnu/libSDL-1.2.so.0
#1 0x101be3cc in CVideoPlayer::open (this=0x10303ff0, fname=..., loop=<optimized out>, useOverlay=<optimized out>) at CVideoHandler.cpp:768
0000002 0x101be7a4 in CVideoPlayer::openAndPlayVideo (this=0x10303ff0, name=..., x=60, y=40, dst=0x0, stopOnKey=<optimized out>) at CVideoHandler.cpp:1011
0000003 0x101454c8 in playIntro () at CMT.cpp:574
0000004 0x1003d64c in main (argc=<optimized out>, argv=<optimized out>) at CMT.cpp:274
----------------------------------------

So I can't upload screenshots and savegames right now.
(0002700)
Ivan (developer)
2012-06-15 22:32

>> boost::too_many_args: format-string referred to less arguments than were passed
Can you give backtrace for that?

>> Error: SDL says that 0x0 resolution is not available!
This happens when VCMI can't read config/*.json files
Make sure that the files are present, not empty and readable by user.
(0002703)
douggie_m (reporter)
2012-06-15 22:56
edited on: 2012-06-15 23:05

> Can you give backtrace for that?
Of course, it is 100% reproducible:

----------------------------------------
Opening StupidAI
Loaded Stupid AI 0.1
CStupidAI [0xec3f5010]: created
CStupidAI [0xec3f5010]: init called, saving ptr to IBattleCallback
[New Thread 0xf36ff450 (LWP 20932)]
const TerrainTile* CGameInfoCallback::getTile(int3, bool) const: -1 -1 -1 is not visible!
const TerrainTile* CGameInfoCallback::getTile(int3, bool) const: -1 -1 -1 is not visible!
const TerrainTile* CGameInfoCallback::getTile(int3, bool) const: -1 -1 -1 is not visible!
Warning: empty path found...
Lost connection to server, ending listening thread!
boost::too_many_args: format-string referred to less arguments than were passed
Something wrong, lost connection while game is still ongoing...
terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::io::too_many_args> >'
  what(): boost::too_many_args: format-string referred to less arguments than were passed

Program received signal SIGABRT, Aborted.
[Switching to Thread 0xf36ff450 (LWP 20932)]
0x0de669ac in *__GI_raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
64 ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) bt
#0 0x0de669ac in *__GI_raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
#1 0x0de6c060 in *__GI_abort () at abort.c:92
0000002 0x0e1409d0 in __gnu_cxx::__verbose_terminate_handler() () from /usr/lib/powerpc-linux-gnu/libstdc++.so.6
0000003 0x0e13d9e8 in ?? () from /usr/lib/powerpc-linux-gnu/libstdc++.so.6
0000004 0x0e13da2c in std::terminate() () from /usr/lib/powerpc-linux-gnu/libstdc++.so.6
0000005 0x0e13ded8 in __cxa_rethrow () from /usr/lib/powerpc-linux-gnu/libstdc++.so.6
0000006 0x101072f0 in CClient::run (this=<optimized out>) at Client.cpp:162
0000007 0x10148180 in operator() (p=<optimized out>, this=<optimized out>) at /usr/include/boost/bind/mem_fn_template.hpp:49
0000008 operator()<boost::_mfi::mf0<void, CClient>, boost::_bi::list0> (f=..., this=<optimized out>, a=...)
    at /usr/include/boost/bind/bind.hpp:253
0000009 operator() (this=<optimized out>) at /usr/include/boost/bind/bind_template.hpp:20
0000010 boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, CClient>, boost::_bi::list1<boost::_bi::value<CClient*> > > >::run (this=<optimized out>) at /usr/include/boost/thread/detail/thread.hpp:62
0000011 0x0e47340c in ?? () from /usr/lib/libboost_thread.so.1.49.0
0000012 0x0ddfa7b0 in start_thread (arg=<optimized out>) at pthread_create.c:306
0000013 0x0df20930 in clone () at ../sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S:123
----------------------------------------

UPD: Oops, I got it on visiting of Learning Stone, not on end of turn. But anyway, it is random and weird. Worth reporting another issue?

> This happens when VCMI can't read config/*.json files

"r" for others everywhere, what can be wrong?

# ls -l /usr/share/vcmi/config/
total 416
-rw-rw-r-- 1 root root 27068 Apr 7 20:46 bankconfig.json
-rw-rw-r-- 1 root root 4918 Sep 5 2011 battles_graphics.json
-rw-rw-r-- 1 root root 1777 Apr 28 14:52 battleStartpos.json
-rw-rw-r-- 1 root root 5726 Apr 17 10:02 bonusnames.json
-rw-rw-r-- 1 root root 2277 Sep 3 2011 buildings5.json
-rw-rw-r-- 1 root root 59338 Apr 7 20:46 buildings.json
-rw-rw-r-- 1 root root 5295 Feb 12 05:28 campaign_regions.json
-rw-rw-r-- 1 root root 2202 May 19 11:56 commanders.json
-rw-rw-r-- 1 root root 853 Aug 31 2011 creature_backgrounds.json
-rw-rw-r-- 1 root root 49278 May 18 17:13 creatures.json
-rw-rw-r-- 1 root root 29575 May 18 17:13 cr_sounds.json
-rw-rw-r-- 1 root root 2209 May 19 11:56 defaultSettings.json
-rw-rw-r-- 1 root root 4050 Sep 3 2011 dwellings.json
-rw-rw-r-- 1 root root 5680 Aug 31 2011 ERMU_to_picture.json
-rw-rw-r-- 1 root root 498 Feb 4 2010 fonts.txt
-rw-rw-r-- 1 root root 2916 Sep 4 2011 hall.json
-rw-rw-r-- 1 root root 34083 Aug 31 2011 heroes.json
-rw-rw-r-- 1 root root 5963 May 20 06:06 mainmenu.json
-rw-rw-r-- 1 root root 1052 Aug 26 2011 minimap.json
-rw-rw-r-- 1 root root 128 Jun 30 2009 NEUTRAL.PAL
-rw-rw-r-- 1 root root 27176 May 18 05:36 obstacles.json
-rw-rw-r-- 1 root root 7608 Aug 21 2011 portraits.json
-rw-rw-r-- 1 root root 17632 Sep 3 2011 puzzle_map.json
-rw-rw-r-- 1 root root 23858 Jun 1 12:10 resolutions.json
-rw-rw-r-- 1 root root 124 Apr 7 20:46 resources.json
-rw-rw-r-- 1 root root 6530 May 21 03:56 spell_info.json
-rw-rw-r-- 1 root root 6967 May 19 11:56 sp_sounds.json
-rw-rw-r-- 1 root root 1386 Apr 7 20:46 startres.json
-rw-rw-r-- 1 root root 970 Sep 3 2011 terrains.json
-rw-rw-r-- 1 root root 146 Feb 9 2011 threatlevel.txt
-rw-rw-r-- 1 root root 1263 Aug 31 2011 town_pictures.json
-rw-rw-r-- 1 root root 636 Sep 3 2011 towns_defs.json
-rw-rw-r-- 1 root root 6521 Aug 31 2011 wall_pos.json

(0002704)
Ivan (developer)
2012-06-16 10:45

>> Oops, I got it on visiting of Learning Stone, not on end of turn.
Actually you got it on level-up. Anyway it should be fixed now.

And try latest revision (2758) - it won't fix "only root" problem but it should print correct error message for it.
(0002713)
douggie_m (reporter)
2012-06-16 16:25

> And try latest revision (2758) - it won't fix "only root" problem but it should print correct error message for it.

@Ivan: Oops, sorry. I haven't read *this* thread. Will try now.
(0002717)
douggie_m (reporter)
2012-06-16 16:52
edited on: 2012-06-16 16:53

> it won't fix "only root" problem but it should print correct error message for it.

I got this:

Assertion 's' failed at pulse/stream.c:1661, function pa_stream_drain(). Aborting.
Aborted

Root playing is still okay.

UPD: I do confirm that learning stone (or lvling up) issue is fixed. Server do not shut down in that case.

(0002720)
Ivan (developer)
2012-06-16 17:01

pulse, pa. That looks like pulseaudio, not VCMI.

Check for messages that start with this:
Last system error was: some-error

Or upload console log (log files won't have these messages)
(0002723)
douggie_m (reporter)
2012-06-16 17:07

root@g5:/home/username/Development/VCMI/vcmi-svn/__dest# exit
username@g5:~/Development/VCMI/vcmi-svn/__dest$ ./usr/bin/vcmiclient
Starting...
Creating console and logfile: 0
Loading settings: 20
VCMI 0.89b (client)
Error: SDL says that 0x0 resolution is not available!
        Initializing screen: 160
        Initializing video: 0
        Initializing minors: 0
        Initializing sound: 20
Initializing screen and sound handling: 20
Loading .lod files: 180
        General text handler: 20
        Hero handler: 80
        Artifact handler: 20
Segmentation fault
username@g5:~/Development/VCMI/vcmi-svn/__dest$ gdb ./usr/bin/vcmiclient
GNU gdb (GDB) 7.4.1-debian
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> [^]
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "powerpc-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>... [^]
Reading symbols from /home/username/Development/VCMI/vcmi-svn/__dest/usr/bin/vcmiclient...done.
(gdb) run
Starting program: /home/username/Development/VCMI/vcmi-svn/__dest/usr/bin/vcmiclient
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/powerpc-linux-gnu/libthread_db.so.1".
Starting...
[New Thread 0xf7f9a450 (LWP 12143)]
0
Loading settings: 20
VCMI 0.89b (client)
[New Thread 0xf779a450 (LWP 12144)]
[New Thread 0xf2d3a450 (LWP 12145)]
Error: SDL says that 0x0 resolution is not available!
        Initializing screen: 160[Thread 0xf2d3a450 (LWP 12145) exited]

        Initializing video: 0
[New Thread 0xf2d3a450 (LWP 12146)]
        Initializing minors: 0
[New Thread 0xf58ff450 (LWP 12147)]
        Initializing sound: 20
Initializing screen and sound handling: 40
Program received signal SIGSEGV, Segmentation fault.
0x0e298fc8 in SDL_CreateYUVOverlay () from /usr/lib/powerpc-linux-gnu/libSDL-1.2.so.0
(gdb) bt
#0 0x0e298fc8 in SDL_CreateYUVOverlay () from /usr/lib/powerpc-linux-gnu/libSDL-1.2.so.0
#1 0x101be718 in CVideoPlayer::open (this=0x10304ff8, fname=..., loop=<optimized out>, useOverlay=<optimized out>) at CVideoHandler.cpp:768
0000002 0x101beaf0 in CVideoPlayer::openAndPlayVideo (this=0x10304ff8, name=..., x=60, y=40, dst=0x0, stopOnKey=<optimized out>) at CVideoHandler.cpp:1011
0000003 0x1014584c in playIntro () at CMT.cpp:574
0000004 0x1003d64c in main (argc=<optimized out>, argv=<optimized out>) at CMT.cpp:274
(gdb)
(0002725)
Ivan (developer)
2012-06-16 17:21

Weird. No read error or anything like that.

Try removing your settings file:
~/.vcmi/config/settings.json

Upload it here as well - I'd like to take a look on it.
(0002726)
douggie_m (reporter)
2012-06-16 17:26

I got another weird problem. Remember that savegame with cyrillic symbols and a lot of archangels? Well, you can't accept the group of units when they want to:

[New Thread 0xec3ff450 (LWP 12465)]
[Thread 0xec3ff450 (LWP 12465) exited]
CStupidAI [0x119e2df8]: actionStarted called
CStupidAI [0x119e2df8]: battleStackMoved called
CStupidAI [0x119e2df8]: battleAttack called
CStupidAI [0x119e2df8]: battleStacksAttacked called
CStupidAI [0x119e2df8]: actionFinished called
CStupidAI [0x119e2df8]: battleEnd called
Warning: an orphaned child!

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xf38ff450 (LWP 12460)]
std::vector<int, std::allocator<int> >::~vector (this=0x48, __in_chrg=<optimized out>) at CCreatureWindow.cpp:788
788 }
(gdb) bt
#0 std::vector<int, std::allocator<int> >::~vector (this=0x48, __in_chrg=<optimized out>) at CCreatureWindow.cpp:788
#1 0x0f9123f4 in InfoAboutHero::Details::~Details() () from /usr/lib/vcmi/libvcmi.so.0
0000002 0x0f904d68 in InfoAboutHero::~InfoAboutHero() () from /usr/lib/vcmi/libvcmi.so.0
0000003 0x101e7f6c in CHeroTooltip::CHeroTooltip (this=0x11a6d998, pos=<error reading variable: value has been optimized out>, hero=0x0) at GUIClasses.cpp:141
0000004 0x100a4c88 in CInfoBar::CVisibleInfo::loadHero (this=<optimized out>, hero=0x0) at AdventureMapClasses.cpp:652
0000005 0x100a597c in CInfoBar::showHeroSelection (this=0x13ca31cc, hero=0x0, onlyUpdate=<optimized out>) at AdventureMapClasses.cpp:914
0000006 0x101644c0 in CPlayerInterface::updateInfo (this=<optimized out>, specific=<optimized out>) at CPlayerInterface.cpp:2163
0000007 0x10164838 in CPlayerInterface::garrisonChanged (this=0x117e36e8, obj=0x119f9800) at CPlayerInterface.cpp:518
0000008 0x101649a4 in CPlayerInterface::stacksRebalanced (this=0x117e36e8, src=..., dst=..., count=<optimized out>) at CPlayerInterface.cpp:2299
0000009 0x1021396c in RebalanceStacks::applyCl (this=0x1184d768, cl=0x117dbdd8) at NetPacksClient.cpp:208
0000010 0x10111a5c in CApplyOnCL<RebalanceStacks>::applyOnClAfter (this=<optimized out>, cl=<optimized out>, pack=<optimized out>) at Client.cpp:72
0000011 0x101071a4 in CClient::handlePack (this=0x117dbdd8, pack=0x1184d768) at Client.cpp:491
0000012 0x1010751c in CClient::run (this=0x117dbdd8) at Client.cpp:151
0000013 0x10148504 in operator() (p=<optimized out>, this=<optimized out>) at /usr/include/boost/bind/mem_fn_template.hpp:49
0000014 operator()<boost::_mfi::mf0<void, CClient>, boost::_bi::list0> (f=..., this=<optimized out>, a=...) at /usr/include/boost/bind/bind.hpp:253
0000015 operator() (this=<optimized out>) at /usr/include/boost/bind/bind_template.hpp:20
0000016 boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, CClient>, boost::_bi::list1<boost::_bi::value<CClient*> > > >::run (this=<optimized out>)
    at /usr/include/boost/thread/detail/thread.hpp:62
0000017 0x0e47340c in ?? () from /usr/lib/libboost_thread.so.1.49.0
0000018 0x0ddfa7b0 in start_thread (arg=<optimized out>) at pthread_create.c:306
(0002727)
douggie_m (reporter)
2012-06-16 17:28
edited on: 2012-06-16 17:30

> Try removing your settings file: ~/.vcmi/config/settings.json

Hmm... It works.

UPD: But hangs.

Loading procedure started!

Reading save signature: 20
Reading handlers: 160
Reading gamestate: 220
        Unpacking and handling defs: 60
        Preparing FoW, roads, rivers,borders: 20
        Making object rects: 20
Initing maphandler: 100
Establishing connection...
Found endpoints:
        0: 127.0.0.1:3030
Trying connection to 127.0.0.1:3030 (0)
Established connection with VCMI 0.89b (server)
Server opened savegame properly.
Sent info to server: 0
Opening VCAI
Loaded VCAI
Opening VCAI
Loaded VCAI
Opening VCAI
Loaded VCAI
Opening StupidAI
Loaded Stupid AI 0.1
CStupidAI [0xed6446e0]: created
CStupidAI [0xed6446e0]: init called, saving ptr to IBattleCallback
gui
10CAdvMapInt *** MA at 0x0

(0002729)
douggie_m (reporter)
2012-06-16 17:42

Also, that savegame (will upload my progress), on an attempt to visit Thieves' Guild:

Opening StupidAI
Loaded Stupid AI 0.1
CStupidAI [0x10f442a8]: created
CStupidAI [0x10f442a8]: init called, saving ptr to IBattleCallback
[New Thread 0xee509450 (LWP 12841)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xee509450 (LWP 12841)]
_wordcopy_bwd_aligned (dstp=-520251252, srcp=1709744096, len=516242984) at wordcopy.c:292
292 wordcopy.c: No such file or directory.
(gdb) bt
#0 _wordcopy_bwd_aligned (dstp=-520251252, srcp=1709744096, len=516242984) at wordcopy.c:292
#1 0x0debfc80 in *__GI_memmove (dest=0x65e8a008, src=<optimized out>, len=2207733944) at memmove.c:102
0000002 0x101fcc64 in __copy_m<unsigned char> (__result=0x65e8a008 "", __last=<optimized out>, __first=<optimized out>) at /usr/include/c++/4.6/bits/stl_algobase.h:366
0000003 __copy_move_a<false, unsigned char const*, unsigned char*> (__last=<optimized out>, __result=0x65e8a008 "", __first=<optimized out>)
    at /usr/include/c++/4.6/bits/stl_algobase.h:384
0000004 __copy_move_a2<false, __gnu_cxx::__normal_iterator<unsigned char const*, std::vector<unsigned char> >, unsigned char*> (__result=0x65e8a008 "", __last=..., __first=...)
    at /usr/include/c++/4.6/bits/stl_algobase.h:422
0000005 copy<__gnu_cxx::__normal_iterator<unsigned char const*, std::vector<unsigned char> >, unsigned char*> (__result=0x65e8a008 "", __last=..., __first=...)
    at /usr/include/c++/4.6/bits/stl_algobase.h:454
0000006 __uninit_copy<__gnu_cxx::__normal_iterator<unsigned char const*, std::vector<unsigned char> >, unsigned char*> (__result=0x65e8a008 "", __last=..., __first=...)
    at /usr/include/c++/4.6/bits/stl_uninitialized.h:95
0000007 uninitialized_copy<__gnu_cxx::__normal_iterator<unsigned char const*, std::vector<unsigned char> >, unsigned char*> (__result=0x65e8a008 "", __last=..., __first=...)
    at /usr/include/c++/4.6/bits/stl_uninitialized.h:119
0000008 __uninitialized_copy_a<__gnu_cxx::__normal_iterator<unsigned char const*, std::vector<unsigned char> >, unsigned char*, unsigned char> (__result=0x65e8a008 "",
    __last=..., __first=...) at /usr/include/c++/4.6/bits/stl_uninitialized.h:259
0000009 vector (__x=..., this=<synthetic pointer>) at /usr/include/c++/4.6/bits/stl_vector.h:280
0000010 CThievesGuildWindow::CThievesGuildWindow (this=0xead011c8, _owner=<optimized out>) at GUIClasses.cpp:5304
0000011 0x1015f6a0 in CPlayerInterface::showThievesGuildWindow (this=<optimized out>, obj=<optimized out>) at CPlayerInterface.cpp:2229
0000012 0x10215b48 in OpenWindow::applyCl (this=0xead06cc0, cl=0x10353a00) at NetPacksClient.cpp:836
0000013 0x10111960 in CApplyOnCL<OpenWindow>::applyOnClAfter (this=<optimized out>, cl=<optimized out>, pack=<optimized out>) at Client.cpp:72
0000014 0x101071a4 in CClient::handlePack (this=0x10353a00, pack=0xead06cc0) at Client.cpp:491
0000015 0x1010751c in CClient::run (this=0x10353a00) at Client.cpp:151
0000016 0x10148504 in operator() (p=<optimized out>, this=<optimized out>) at /usr/include/boost/bind/mem_fn_template.hpp:49
0000017 operator()<boost::_mfi::mf0<void, CClient>, boost::_bi::list0> (f=..., this=<optimized out>, a=...) at /usr/include/boost/bind/bind.hpp:253
0000018 operator() (this=<optimized out>) at /usr/include/boost/bind/bind_template.hpp:20
0000019 boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, CClient>, boost::_bi::list1<boost::_bi::value<CClient*> > > >::run (this=<optimized out>)
    at /usr/include/boost/thread/detail/thread.hpp:62
0000020 0x0e47340c in ?? () from /usr/lib/libboost_thread.so.1.49.0
0000021 0x0ddfa7b0 in start_thread (arg=<optimized out>) at pthread_create.c:306
0000022 0x0df20930 in clone () at ../sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S:123
(0002730)
douggie_m (reporter)
2012-06-16 17:54
edited on: 2012-06-16 17:57

And this (that was just on end of turn):

----------------------------------------
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xec3ff450 (LWP 13096)]
0x0f9057e0 in ArmyDescriptor::getStrength() const () from /usr/lib/vcmi/libvcmi.so.0
(gdb) bt
#0 0x0f9057e0 in ArmyDescriptor::getStrength() const () from /usr/lib/vcmi/libvcmi.so.0
#1 0x0c113d30 in evaluateDanger(CGObjectInstance const*) () from /usr/lib/vcmi/AI/libVCAI.so
0000002 0x0c1138fc in evaluateDanger(int3 const&, CGHeroInstance const*) () from /usr/lib/vcmi/AI/libVCAI.so
0000003 0x0c11acd8 in isSafeToVisit(CGHeroInstance const*, int3 const&) () from /usr/lib/vcmi/AI/libVCAI.so
0000004 0x0c129504 in CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}::operator()(CGObjectInstance const*) const () from /usr/lib/vcmi/AI/libVCAI.so
0000005 0x0c13a864 in __gnu_cxx::__normal_iterator<CGObjectInstance const**, std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> > > std::__find_if<__gnu_cxx::__normal_iterator<CGObjectInstance const**, std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> > >, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}>(CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}, std::random_access_iterator_tag) () from /usr/lib/vcmi/AI/libVCAI.so
0000006 0x0c135a1c in __gnu_cxx::__normal_iterator<CGObjectInstance const**, std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> > > std::find_if<__gnu_cxx::__normal_iterator<CGObjectInstance const**, std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> > >, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}>(CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}) () from /usr/lib/vcmi/AI/libVCAI.so
0000007 0x0c131b40 in __gnu_cxx::__normal_iterator<CGObjectInstance const**, std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> > > std::remove_if<__gnu_cxx::__normal_iterator<CGObjectInstance const**, std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> > >, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}>(CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}) () from /usr/lib/vcmi/AI/libVCAI.so
0000008 0x0c12f474 in boost::range_iterator<std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> > >::type boost::range::remove_if<std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> >, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}>(boost::range_iterator&, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}) () from /usr/lib/vcmi/AI/libVCAI.so
0000009 0x0c12dac4 in void erase_if<std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> >, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}>(std::vector<CGObjectInstance const*, std::allocator<CGObjectInstance const*> >&, CGoal::whatToDoToAchieve()::{lambda(CGObjectInstance const*)0000009}) ()
   from /usr/lib/vcmi/AI/libVCAI.so
0000010 0x0c128174 in CGoal::whatToDoToAchieve() () from /usr/lib/vcmi/AI/libVCAI.so
0000011 0x0c121414 in VCAI::striveToGoal(CGoal const&) () from /usr/lib/vcmi/AI/libVCAI.so
0000012 0x0c11858c in VCAI::makeTurnInternal() () from /usr/lib/vcmi/AI/libVCAI.so
0000013 0x0c117e10 in VCAI::makeTurn() () from /usr/lib/vcmi/AI/libVCAI.so
0000014 0x0c1c6e68 in boost::_mfi::mf0<void, VCAI>::operator()(VCAI*) const () from /usr/lib/vcmi/AI/libVCAI.so
0000015 0x0c1c6d24 in void boost::_bi::list1<boost::_bi::value<VCAI*> >::operator()<boost::_mfi::mf0<void, VCAI>, boost::_bi::list0>(boost::_bi::type<void>, boost::_mfi::mf0<void, VCAI>&, boost::_bi::list0&, int) () from /usr/lib/vcmi/AI/libVCAI.so
0000016 0x0c1c6c8c in boost::_bi::bind_t<void, boost::_mfi::mf0<void, VCAI>, boost::_bi::list1<boost::_bi::value<VCAI*> > >::operator()() () from /usr/lib/vcmi/AI/libVCAI.so
0000017 0x0c1c510c in boost::detail::thread_data<boost::_bi::bind_t<void, boost::_mfi::mf0<void, VCAI>, boost::_bi::list1<boost::_bi::value<VCAI*> > > >::run() ()
   from /usr/lib/vcmi/AI/libVCAI.so
0000018 0x0e47340c in ?? () from /usr/lib/libboost_thread.so.1.49.0
0000019 0x0ddfa7b0 in start_thread (arg=<optimized out>) at pthread_create.c:306
0000020 0x0df20930 in clone () at ../sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S:123
----------------------------------------

100% reproducible, just end turn (savegame test34 will follow).

(0002731)
douggie_m (reporter)
2012-06-16 18:01

By the way, I still can't proceed to a big army in some town to show you the actually reported issue here.
(0002732)
Ivan (developer)
2012-06-16 18:02

1) Crash on accepting group of units: will fix
2) Game hangs - not sure...
3) Thieves guild - not reproducible, not sure what's going on.
4) This is already reported several times bug 0001008
(0002733)
douggie_m (reporter)
2012-06-16 18:15

@Ivan 0002732:
Oh, yes. Okay. It'd be great to have some fix / more detailed logging, and so.
Good luck.
Time to watch RUS-GRE.
(0002740)
Ivan (developer)
2012-06-16 20:45

regarding game hanging - create backtrace from all threads, from both client and server:
(gdb) thread apply all bt
(0002747)
douggie_m (reporter)
2012-06-18 17:21
edited on: 2012-06-18 17:51

Will build the latest SVN and test.

UPD: Done. That game is so buggy... Enter Tavern in town - crash. End turn - crash.
Sorry, I'm going to use only original maps.

(0002805)
douggie_m (reporter)
2012-07-19 19:24

Now it prints: ``System message: Server encountered a problem: Cannot make garrison swap, not enough free slots!'' instead of crashing. I suppose it is okay. Issue can be closed.
(0002808)
Ivan (developer)
2012-07-19 20:29

I still would like to see armies that can cause this - you should get normal H3 popup instead of message in console which may not be visible at all.
(0002809)
douggie_m (reporter)
2012-07-20 14:36
edited on: 2012-07-20 15:04

@Ivan: okay; for example, get this savegame http://bugs.vcmi.eu/view.php?id=1038 [^] , go to the town, and hire all units. Then try to move hero to garrison.

UPD: Do not upgrade Cyra's units to get this. If they are all upgraded, they do merge absolutely perfect with garrison's just-hired ones. Also, this was (and is now, just in the form of stdout message) always reproducible when armies are "un-mergable". Just get a lot of guys in garrison, they must be not the same as yours (i.e. 7 slots must be overfull), and try to merge. In the last month, I just got that I shall never try to merge un-mergable armies. Only when looking on issue 1038, I tried it again (to be sure it is stil crash ;)

(0002812)
Ivan (developer)
2012-07-20 17:38

Ah. That looks like 0000531
Closing this one then.

- Issue History
Date Modified Username Field Change
2012-06-13 19:04 douggie_m New Issue
2012-06-13 19:04 douggie_m Status new => assigned
2012-06-13 19:04 douggie_m Assigned To => Tow
2012-06-13 19:21 Warmonger Note Added: 0002671
2012-06-13 19:30 Ivan Note Added: 0002672
2012-06-14 17:08 douggie_m Note Added: 0002681
2012-06-15 16:00 Ivan Note Added: 0002694
2012-06-15 21:52 douggie_m Note Added: 0002695
2012-06-15 22:32 Ivan Note Added: 0002700
2012-06-15 22:56 douggie_m Note Added: 0002703
2012-06-15 23:05 douggie_m Note Edited: 0002703 View Revisions
2012-06-16 10:45 Ivan Note Added: 0002704
2012-06-16 16:25 douggie_m Note Added: 0002713
2012-06-16 16:52 douggie_m Note Added: 0002717
2012-06-16 16:53 douggie_m Note Edited: 0002717 View Revisions
2012-06-16 17:01 Ivan Note Added: 0002720
2012-06-16 17:07 douggie_m Note Added: 0002723
2012-06-16 17:21 Ivan Note Added: 0002725
2012-06-16 17:26 douggie_m Note Added: 0002726
2012-06-16 17:27 douggie_m File Added: settings.json
2012-06-16 17:28 douggie_m Note Added: 0002727
2012-06-16 17:30 douggie_m Note Edited: 0002727 View Revisions
2012-06-16 17:42 douggie_m Note Added: 0002729
2012-06-16 17:44 douggie_m File Added: test2.savegame.tar.bz2
2012-06-16 17:54 douggie_m Note Added: 0002730
2012-06-16 17:55 douggie_m Note Edited: 0002730 View Revisions
2012-06-16 17:57 douggie_m Note Edited: 0002730 View Revisions
2012-06-16 17:57 douggie_m File Added: test34.savegame.tar.bz2
2012-06-16 18:01 douggie_m Note Added: 0002731
2012-06-16 18:02 Ivan Note Added: 0002732
2012-06-16 18:15 douggie_m Note Added: 0002733
2012-06-16 20:45 Ivan Note Added: 0002740
2012-06-16 20:45 Ivan Assigned To Tow => Ivan
2012-06-18 17:21 douggie_m Note Added: 0002747
2012-06-18 17:51 douggie_m Note Edited: 0002747 View Revisions
2012-07-19 19:24 douggie_m Note Added: 0002805
2012-07-19 20:29 Ivan Note Added: 0002808
2012-07-20 14:36 douggie_m Note Added: 0002809
2012-07-20 14:37 douggie_m Note Edited: 0002809 View Revisions
2012-07-20 15:02 douggie_m Note Edited: 0002809 View Revisions
2012-07-20 15:04 douggie_m Note Edited: 0002809 View Revisions
2012-07-20 17:38 Ivan Note Added: 0002812
2012-07-20 17:38 Ivan Status assigned => closed
2012-07-20 17:38 Ivan Resolution open => no change required

Site | Forums | Wiki | Slack | GitHub


Copyright © 2000 - 2024 MantisBT Team
Hosting provided by DigitalOcean