Galleondragon / qb64

Automatically exported from code.google.com/p/qb64
Other
265 stars 65 forks source link

Windows Command Processor stopped working #64

Closed quantuumsnot closed 6 years ago

quantuumsnot commented 6 years ago

This happens after a couple of simple test scripts (mainly PRINT with ERROR catching):

Problem signature: Problem Event Name: BEX Application Name: cmd.exe Application Version: 6.1.7601.17514 Application Timestamp: 4ce78e2b Fault Module Name: StackHash_0a9e Fault Module Version: 0.0.0.0 Fault Module Timestamp: 00000000 Exception Offset: 00ac2a70 Exception Code: c0000005 Exception Data: 00000008 OS Version: 6.1.7601.2.1.0.256.1 Locale ID: 1033 Additional Information 1: 0a9e Additional Information 2: 0a9e372d3b4ad19135b953a78882e789 Additional Information 3: 0a9e Additional Information 4: 0a9e372d3b4ad19135b953a78882e789

This is the other crash:

Problem signature: Problem Event Name: APPCRASH Application Name: qb64.exe Application Version: 0.0.0.0 Application Timestamp: 5b773c1b Fault Module Name: ANSI32.dll Fault Module Version: 1.8.4.0 Fault Module Timestamp: 5af5890c Exception Code: c0000005 Exception Offset: 000024be OS Version: 6.1.7601.2.1.0.256.1 Locale ID: 1033 Additional Information 1: a7aa Additional Information 2: a7aa91f17ea749d42a4de3b390fa5b3d Additional Information 3: a7aa Additional Information 4: a7aa91f17ea749d42a4de3b390fa5b3d

System is Windows 7 SP1 x64 on Intel i7-3610QM cpu

FellippeHeitor commented 6 years ago

Can you share the code that's causing the issue? Does it happen every time? Please share the steps to reproduce the crash if possible.

quantuumsnot commented 6 years ago

The code from Detect division by zero 10 ON ERROR GOTO 60 20 PRINT 2/3 30 PRINT 3/5 40 PRINT 4/0 50 END 60 IF ERR=11 THEN PRINT "Division by zero in line"ERL:RESUME 50

Same without ERL: RESUME 50

FellippeHeitor commented 6 years ago

Can't reproduce the crash just by running the sample above. Are there any extra steps?

Also: Please report what you have in Help->About.

quantuumsnot commented 6 years ago

This time qb64 crashed directly when started with BEX (problem event name, already pasted in the first post) then started as normal

Help > About:

QB64 Version 1.2 Revision 20180228/86 From git 6cb81e1

FellippeHeitor commented 6 years ago

I see a lot of people reporting the same type of error in this thread: https://answers.microsoft.com/en-us/windows/forum/windows_other-windows_programs/problem-event-name-bex-error-message/cf5baf73-0877-4070-abfb-a2c3a17a9e10

One of the solutions was:

right click on my computer go to properties click on advanced system settings under performance, click settings click the Data Execution Prevention tab, and then click Turn on DEP for all programs and services except those I select. click Add, browse to the executable file for the program and add it.

Can you check if that solves it on your machine?

I want to add that I'm running the latest dev build of QB64 on a Windows 7 machine, SP1 x64 on Intel Core i3-4130 @ 3.40GHz; no issues on my end - it could be something local to your setup.

quantuumsnot commented 6 years ago

DEP was completely disabled on the machine due to some problems with old games (like Dark Reign for example)

Nope, it doesn't work on the second and more clean machine - E5-2660 with the same Windows 7 SP1 x64

FellippeHeitor commented 6 years ago

Please provide steps to reproduce the issue, if any, or this will have to be considered an isolated case and closed.

quantuumsnot commented 6 years ago
  1. Downloaded qb64 1.2 (as already stated)

2a. Started qb64 from command prompt as administrator or 2b. Started qb64 directly with double-clicking on the executable

  1. Ran this code (as already stated):
    10 ON ERROR GOTO 60
    20 PRINT 2/3
    30 PRINT 3/5
    40 PRINT 4/0
    50 END
    60 IF ERR=11 THEN PRINT "Division by zero in line"ERL:RESUME 50
  2. DEP is completely disabled, also no antivirus/antimalware software installed
  3. Above steps were performed also and on a Win XP SP2 x64/Win 10 Pro x64 virtual machines with the same result
FellippeHeitor commented 6 years ago

I have asked in the forum for more people willing to give it a test under similar conditions and am waiting for replies. Please follow along if you have a forum account (or register for one if you'd like to): https://www.qb64.org/forum/index.php?topic=534.0

FellippeHeitor commented 6 years ago

Also: does it happen with the latest stable build from qb64.org as well?

quantuumsnot commented 6 years ago

Your link is broken - leads to empty github page :)

On QB64 Stable it even cannot create executable without 'stopped working' notification window. Same errors, empty compilelog.txt, not possible to close the QB64 window (only with killing the process tree)

Anyway I made another test - this time on another machine (E5-2660) FULL CLONE of the laptop but with different drivers:

1) QB64 Version 1.2 Revision 20180228/86 From git 6cb81e1

It compiles the executable and runs it with correct output, both when ran from command prompt or double-clicked:

5
2
2
1.#INF
  1. When I delete the compiled executable and click the 'Run > Start' command it just shows and closes command prompt window for a fraction of second. Executable is not created again, clicking on 'Run > Make EXE Only' does nothing. I must close the IDE and start it again to be able to create the executable

  2. Got another result from laptop - when the window manages to stay open I can read the error output in 'Status' area: 'C++ Compilation failed (Check .\internal\temp\compilelog.txt)' but the file is empty (after or before closing QB64 windows)

  3. There's another issue found during testing - I'm using MSI Afterburner with Riva Tuner on both machines. MSI/Riva shows the OSD info (FPS, CPU/GPU temp, Frequencies ...) at the top right corner and this obstructs the visibility. There's not an option to stop MSI everytime when I want to code something on QB64

FellippeHeitor commented 6 years ago

1- different drivers; that's probably the answer to your issues.

2- that's known: #63 - just hit space on an empty line and it should work for now.

3- that usually happens when the final resulting exe cannot be found - likely something could be preventing these executables from being saved (or even deleting them immediately after creation)

4- that could be using opengl and interacting weirdly with QB64. Does disabling it fix it?

5- did you check the forum link? I got some replies already.

quantuumsnot commented 6 years ago
  1. I'll timidly ask why it's possible a programming language and IDE from decades to have problems with drivers? Have a friend with 2 identical machines with the same software (same cpus i7-2500k, an ASUS motherboard, ram, GTX960 and 1TB hdds, data is realtime synced between them) and he told me QB64 crashes on one of the machines

  2. Nothing prevents them to be saved, I'm talking about that file_exist() check is missing

  3. That's the opposite of what I'm pointing to - some OSD info applications interfere with the QB64 window to a level where the user cannot see well the menus or part of the code, and it will be stupid to make the user to disable his app just to write some BASIC

FellippeHeitor commented 6 years ago

why it's possible a programming language and IDE from decades to have problems with drivers?

QB64 is not Qbasic, although we strive for retro compatibility. It's a modern application like any other you'll run. OpenGL is used for rendering. OpenAL for sound. NanoJpg for image loading. The list goes on.

I'm sorry to hear you're having problems, but we can't seem to figure the issue for now. Give us time and an answer may arise.