The International Simutrans Forum

 

Author Topic: [solved]r2295 - Crash when buildind a bridge on the stop  (Read 1975 times)

0 Members and 1 Guest are viewing this topic.

Offline z9999

  • Devotees (Inactive)
  • *
  • Posts: 848
[solved]r2295 - Crash when buildind a bridge on the stop
« on: February 06, 2009, 05:05:54 PM »
When building bridge and other end is station, Simutrans crashes.

Quote
Message: brueckenbauer_t::baue():   called on 44,53 for bridge type 'tb_classic_road'
Message: brueckenbauer_t::baue():   build from 44,53,-1
FATAL ERROR: unknown
pure virtual function call
Aborting program execution ...

Quote
sim.exe caused an Integer Divide By Zero at location 0058a36d in module sim.exe.

Registers:
eax=0000000f ebx=0023ea40 ecx=00000000 edx=00000000 esi=006d0074 edi=00730070
eip=0058a36d esp=0023e438 ebp=0023e9c8 iopl=0         nv up ei pl zr ac po nc
cs=001b  ss=0023  ds=0023  es=0023  fs=003b  gs=0000             efl=00000256

Call stack:
0058A36D  sim.exe:0058A36D  log_t::fatal(char const*, char const*, ...)  log.cc:238
   ...
   if(old_level>4) {
   // generate a division be zero error, if the user request it
>   printf("%i",15/make_this_a_division_by_zero);
   make_this_a_division_by_zero &= 0xFF;
   }
   ...

00402EDC  sim.exe:00402EDC  brueckenbauer_t::baue(karte_t*, spieler_t*, koord, bruecke_besch_t const*)  brueckenbauer.cc:371
   ...
   baue_bruecke(welt, sp, gr->get_pos(), end, zv, besch, wegbauer_t::leitung_besch );
   } else {
>   baue_bruecke(welt, sp, gr->get_pos(), end, zv, besch, weg->get_besch() );
   }
   return NULL;
   ...

0058735E  sim.exe:0058735E  karte_t::interactive()  simworld.cc:4420
   ...
   
   if (!swallowed) {
>   interactive_event(ev);
   }
   
   ...

005B0483  sim.exe:005B0483  WinMain  simsys_w16.cc:756
   ...
   GetWindowRect(GetDesktopWindow(), &MaxSize);
   
>   simu_main(argc, argv);
   
   #ifdef MULTI_THREAD
   ...

00401247  sim.exe:00401247
00401298  sim.exe:00401298
7C817067  kernel32.dll:7C817067  RegisterWaitForInputIdle

« Last Edit: February 08, 2009, 07:57:44 AM by z9999 »

Offline gerw

  • Coder/patcher
  • *
  • Posts: 618
Re: r2295 - Crash when buildind a bridge on the stop
« Reply #1 on: February 07, 2009, 08:19:13 AM »
   if(old_level>4) {
   // generate a division be zero error, if the user request it
>   printf("%i",15/make_this_a_division_by_zero);
   make_this_a_division_by_zero &= 0xFF;
   }
:) Nice comment. The user want a bug? He get one.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10818
  • Languages: De,EN,JP
Re: r2295 - Crash when buildind a bridge on the stop
« Reply #2 on: February 07, 2009, 08:08:49 PM »
But before the fatal::error xyz is printed on the screen. I think it is a pure virtaul call, since the halt was not properly removed.