Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compiler silently fails when output file isn't writeable. #4247

Open
flysand7 opened this issue Sep 15, 2024 · 0 comments
Open

Compiler silently fails when output file isn't writeable. #4247

flysand7 opened this issue Sep 15, 2024 · 0 comments
Labels

Comments

@flysand7
Copy link
Contributor

Context

  • Odin: dev-2024-09:d2d202673
  • OS: Windows 10 Unknown Edition (00000064) (version: 22H2), build 19045.4780
  • CPU: 12th Gen Intel(R) Core(TM) i5-12500H
  • RAM: 16088 MiB
  • Backend: LLVM 18.1.8

Description

On windows executables are denied write operations whenever they are being executed. Therefore an attempt to overwrite the executable while it's running will fail. The problem is that whenever odin fails to write to the target executable, due to code of this executable file currently being executed, the compiler will finish compilation without errors.

Whenever a target executable is unable to be written an error message is expected from the compiler.

Reproduction

  1. Compile any executable
  2. Run under debugger, breakpoint anywhere
  3. Compile a new executable, with modified source (it will appear to have finshed successfully)
  4. Run the program in a terminal, the output doesn't change.

The compiler is expected to print errors on step 3, which it currently does not.

@laytan laytan added the bug label Oct 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants