20 December 2022, 19:23 | #1 |
Registered User
Join Date: Apr 2018
Location: Germany
Posts: 189
|
Compiled executable crashes after exit
Im playing around with the old BlitzBasic 2.1, I recently installed it using The Ultimate Blitz Basic 2.1+ CD.
And I noticed that the executables I create always crash some seconds after they seemingly successfully exited to Workbench. It does not happen when I click "Compile & Run" in TED. Then there is no crash. But when the binary created in TED with "Create executable.." is started from Workbench it crashes, see the attachement. This is an WinUAE emaulated A1200 with Basic OS3.1 installation. The code looks like this: Code:
;Open a screen with 256 colors Screen 0,0,0,320,256,8,0,"DonkyeKong",1,2 ScreensBitMap 0,0 x = 160 - 8 xmax = 160 + 8 y = 128 - 8 For i=0 To 255 Plot x,y,i x+1 If x > xmax x = 160 - 8 y+1 EndIf Next MouseWait End |
20 December 2022, 20:19 | #2 |
Registered User
Join Date: Jun 2009
Location: Dublin, then Glasgow
Posts: 6,334
|
You need to have the statement WBStartup in your code (I usually add it at the top). This is needed for Blitz to add the code necessary for handling communications with Workbench. If it's left out, the executable will work fine from the Shell (and directly from Blitz), but will crash when run from Workbench.
|
21 December 2022, 08:26 | #3 |
Registered User
Join Date: Apr 2018
Location: Germany
Posts: 189
|
Ah this fixed it. And it's a wonderfully easy solution:-)
Thank you very much! |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Vaporwave Voyager 3.x+ compiled for 68k | ShenLong | request.Apps | 1 | 14 March 2021 02:05 |
Can I get my original code from my old compiled projects? | vroom6sri | Coders. AMOS | 6 | 24 April 2019 20:42 |
XPM compiled! | Noth | support.Amix | 1 | 11 May 2016 19:18 |
Winuae compiled with Intel c/c++ compiler | Jgames | support.WinUAE | 4 | 29 December 2009 17:41 |
WinUAE crashes on exit | glwxxx | support.WinUAE | 13 | 19 August 2006 11:41 |
|
|