Console program suddenly Demands "Admin" privileges

Everything else that doesn't fall into one of the other PB categories.
User avatar
Vernostonos
User
User
Posts: 58
Joined: Thu Jul 02, 2020 9:52 pm

Console program suddenly Demands "Admin" privileges

Post by Vernostonos »

I wrote two separate console programs that use the terminal window. They both have the same code initially in the beginning to setup the window size. However what is strange one demands to be ran with Admin privileges when compiled to an exe. I have not coded anything in such a way for my program to require this.

I have checked over my compiler settings and see nothing out of the ordinary. What could this be?
Marc56us
Addict
Addict
Posts: 1477
Joined: Sat Feb 08, 2014 3:26 pm

Re: Console program suddenly Demands "Admin" privileges

Post by Marc56us »

This can happen (for example) if the program tries to write (i.e. to a ini/prefs file) to a location normally reserved for an admin account, like ProgramFiles or the root of the system disk (C:\)
:wink:
User avatar
Vernostonos
User
User
Posts: 58
Joined: Thu Jul 02, 2020 9:52 pm

Re: Console program suddenly Demands "Admin" privileges

Post by Vernostonos »

Interesting, however neither program writes any information to the hard drive.
Post Reply