Author Topic: error id retured 1 exit status version 16.01  (Read 17262 times)

Offline 0_0

  • Single posting newcomer
  • *
  • Posts: 7
error id retured 1 exit status version 16.01
« on: October 27, 2017, 04:11:02 pm »
I have been using code blocks for close to two months.

Recently, I encounter this problem where very new project(under console application) I created can only be compiled once. The next time I tried to compile it, it shows the error shown in the picture.

These files requires administrator permission to be removed(I am currently using the administrator account for my pc).

I think that the files might still be running on my GCC (even though when I end my program I made sure that it is terminated).

It says that I need admin rights to access the file bin\Release

I have also tried to disable the firewall of my Mcafee.


My code blocks version 16.01

Anyone knows how to solve this issue?

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: error id retured 1 exit status version 16.01
« Reply #1 on: October 27, 2017, 04:35:48 pm »
3 causes come in mind:
1) Your program crashes and runs in the background, Have you checked with the task manager if your program is closed?
2) Your anti virus thinks gcc is a virus and blocks all executable generated by it... Try to disable the anti virus, not the firewall (firewall is versus internet and has nothing to do with all this)...
3) You use a write protected folder to create your programs. Have you checked if the rights are correct?

Offline 0_0

  • Single posting newcomer
  • *
  • Posts: 7
Re: error id retured 1 exit status version 16.01
« Reply #2 on: October 28, 2017, 09:48:48 am »
I have checked my task manager, gcc is terminated.

When you say disable anti-virus, you meant that I should turn off the real-time scanning? I tried doing so but it does't work.

I have also checked that my files are not saved as write protected folder.

I tried resetting my compiler to the default setting but I keep having an error message(I have attached a screenshot of that error message).

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7256
Re: error id retured 1 exit status version 16.01
« Reply #3 on: October 28, 2017, 10:29:53 am »
I have checked my task manager, gcc is terminated.

And your self-compiled exe ?

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: error id retured 1 exit status version 16.01
« Reply #4 on: October 29, 2017, 10:32:16 pm »
Quote
I have checked my task manager, gcc is terminated.
gcc and codeblocks works all as expected. Your problem is that the gcc can not write to your output file. This can have this reasons:
1) Windows is blocking the write access
   a) The file is write protected
   b) The file is in a special path where you don't have write access
   c) Windows blocks the write access because the executable is currently running
2) The anti virus is blocking the write access to the executable (not the firewall but the normal anti virus... avast, avg  or whatever...)

So you have nothing to change in codeblocks.. Can you delete the executable from the explorer?

Offline 0_0

  • Single posting newcomer
  • *
  • Posts: 7
Re: error id retured 1 exit status version 16.01
« Reply #5 on: October 30, 2017, 07:46:47 am »
I have checked my task manager, gcc is terminated.

And your self-compiled exe ?

I checked that it is terminated too.

Offline 0_0

  • Single posting newcomer
  • *
  • Posts: 7
Re: error id retured 1 exit status version 16.01
« Reply #6 on: October 30, 2017, 07:50:17 am »
Quote
I have checked my task manager, gcc is terminated.
gcc and codeblocks works all as expected. Your problem is that the gcc can not write to your output file. This can have this reasons:
1) Windows is blocking the write access
   a) The file is write protected
   b) The file is in a special path where you don't have write access
   c) Windows blocks the write access because the executable is currently running
2) The anti virus is blocking the write access to the executable (not the firewall but the normal anti virus... avast, avg  or whatever...)

So you have nothing to change in codeblocks.. Can you delete the executable from the explorer?
I can't delete the executable from my file explorer.

I think it should be  b) The file is in a special path where you don't have write access.

But how do I change the path where I save the files?


Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: error id retured 1 exit status version 16.01
« Reply #7 on: October 30, 2017, 09:38:49 am »
Quote
I think it should be  b) The file is in a special path where you don't have write access.
I personally don't think so, because if this is the case you should never been able to create the file in the first place...

If this is the case, create the project in a sub folder of your "My documents" directory. Or copy this project to the "My documents" folder. The projects use relative paths so all should work...

This is in general a windows problem and not a codeblocks problem so i think this is the wrong place to ask for help. Look at this link
https://www.online-tech-tips.com/software-reviews/how-to-fix-access-is-denied-file-may-be-in-use-or-sharing-violation-errors-in-windows/
maybe it helps.

I personally think your anti virus is blocking you.... You should deactivate it completely.

Offline sodev

  • Lives here!
  • ****
  • Posts: 500
Re: error id retured 1 exit status version 16.01
« Reply #8 on: October 31, 2017, 08:05:40 am »
If its not Windows Defender that blocks access, maybe you created a file which name ends with a whitespace? Because while these can be created programatically, you cant delete them through the user interface.

But yeah, this is sort of off-topic here.

Offline 0_0

  • Single posting newcomer
  • *
  • Posts: 7
Re: error id retured 1 exit status version 16.01
« Reply #9 on: November 01, 2017, 04:30:36 am »
Hi, I have managed to solved the issue by reinstalling codeblocks multiple times (about 4 times).

Thank you very much for your help!

Offline sodev

  • Lives here!
  • ****
  • Posts: 500
Re: error id retured 1 exit status version 16.01
« Reply #10 on: November 01, 2017, 09:29:59 am »
No, that didnt solve your problem! Its just a matter of time until it reappears. But well, when it happens again, the next step is to reinstall Windows multiple times :P

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: error id retured 1 exit status version 16.01
« Reply #11 on: November 01, 2017, 05:06:20 pm »

Offline 0_0

  • Single posting newcomer
  • *
  • Posts: 7
Re: error id retured 1 exit status version 16.01
« Reply #12 on: November 06, 2017, 12:18:55 pm »
No, that didnt solve your problem! Its just a matter of time until it reappears. But well, when it happens again, the next step is to reinstall Windows multiple times :P

yeah. That didn't solve the problem.

Do you know how reinstall windows without losing any other programs on your computer? Do I need a vm to do so?

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: error id retured 1 exit status version 16.01
« Reply #13 on: November 06, 2017, 05:07:47 pm »
the next step is to reinstall Windows multiple times :P
this was sarcastic...
the base problem seems to be windows 10 with the restricted malware policy. I don't have windows 10 so i can not help you with this.

From this*) i can asume you are using one of the default list directories to store your project. Can you try to use a flash drive to store your project, or do you have an additional drive in your pc?

*) https://www.helpnetsecurity.com/2017/07/03/windows-10-protect-ransomware/

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: error id retured 1 exit status version 16.01
« Reply #14 on: November 06, 2017, 05:11:28 pm »
you may also find some useful information here: https://blogs.windows.com/windowsexperience/2017/06/28/announcing-windows-10-insider-preview-build-16232-pc-build-15228-mobile/#6qWsLudrUdGwJ86r.97 in the chapter "Introducing Controlled folder access in Windows Defender Antivirus: "