The International Simutrans Forum

 

Author Topic: r2101 - Crash when rotate map  (Read 2957 times)

0 Members and 1 Guest are viewing this topic.

Offline z9999

  • Devotees (Inactive)
  • *
  • Posts: 848
r2101 - Crash when rotate map
« on: November 09, 2008, 10:52:14 AM »
simutrans r2101 GDI

When I rotate map, simutrans always crash.
There is no useful information in simu.log.

Offline Frank

  • Inactive/Retired
  • *
  • Posts: 1431
  • Languages: DE
Re: r2101 - Crash when rotate map
« Reply #1 on: November 09, 2008, 05:08:29 PM »
I compile r2101 with MS VC++ EE 2005 on WinXP (de)

no problems

test pak64 svn and pak.german

Offline gerw

  • Coder/patcher
  • *
  • Posts: 618
Re: r2101 - Crash when rotate map
« Reply #2 on: November 09, 2008, 05:31:30 PM »
I compiled with gcc4 and linux and couldn't observe crashes during rotation.

Offline z9999

  • Devotees (Inactive)
  • *
  • Posts: 848
Re: r2101 - Crash when rotate map
« Reply #3 on: November 09, 2008, 05:43:31 PM »
Thanks for information.
I tried the version on nightly site, and they didn't crash.

It seems to happen only with my compiled version. (msys MinGW gcc3)

Dr.MinGW report
Quote
Registers:
eax=0000003f ebx=05a4ca78 ecx=006331ac edx=05a4ca78 esi=006d0074 edi=00730070
eip=005f84f8 esp=0023eeec ebp=0023f298 iopl=0         nv up ei pl nz ac pe nc
cs=001b  ss=0023  ds=0023  es=0023  fs=003b  gs=0000             efl=00000212

Call stack:
005F84F8  simutrans-.exe:005F84F8  quickstone_tpl<convoi_t>::operator->() const  quickstone_tpl.h:175
   ...
   T* operator->() const
   {
>   return data[entry];
   }
   
   ...

00579922  simutrans-.exe:00579922  karte_t::interactive()  simworld.cc:4334
   ...
   
   if (!swallowed) {
>   interactive_event(ev);
   }
   
   ...

005A0F33  simutrans-.exe:005A0F33  WinMain  simsys_w16.cc:756
00401247  simutrans-.exe:00401247
00401298  simutrans-.exe:00401298
7C817067  kernel32.dll:7C817067  RegisterWaitForInputIdle

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10822
  • Languages: De,EN,JP
Re: r2101 - Crash when rotate map
« Reply #4 on: November 09, 2008, 06:45:24 PM »
This look most liekely like an access at an illegal halthandle_t. But is is hard to debug. You may try valgrind to find this error.

Offline z9999

  • Devotees (Inactive)
  • *
  • Posts: 848
Re: r2101 - Crash when rotate map
« Reply #5 on: November 09, 2008, 06:53:27 PM »
Sorry, I can't understand the meaning what you said.
This also happen with startup map, which don't have halt.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10822
  • Languages: De,EN,JP
Re: r2101 - Crash when rotate map
« Reply #6 on: November 09, 2008, 07:01:04 PM »
valgrind is a tools to find illegal pointer access (but only for Linux :()

quickstones are only used for convoi pointers and halt pointers. Thus such an acess con be only due to a convoi or a halt (and oil rigs would be halts too). But I am not sure, what goes wrong here.

Offline z9999

  • Devotees (Inactive)
  • *
  • Posts: 848
Re: r2101 - Crash when rotate map
« Reply #7 on: November 09, 2008, 07:06:39 PM »
Thank you. Yes, my startup map have a oil rig.

Offline z9999

  • Devotees (Inactive)
  • *
  • Posts: 848
[solved]Re: r2101 - Crash when rotate map
« Reply #8 on: November 10, 2008, 07:54:48 AM »
I compiled r2107, crash problem didn't happen anymore.
Somethig was wrong with me. Thank you for many help.