You can delete entire hard drives in the "Files" tab. Please remove this feature.
This is a real story. A freshman had been using Code::Blocks while learning C. He placed all source code files under a folder named "c" under his Desktop. He tried to delete the entire folder using the "Files" tab in Code::Blocks. However, he accidentally deleted "C:\" without being aware that this means the entire C drive. As a result, almost all user files were deleted, and all system files survived (since they are protected). Fortunately, there was no valuable data on his computer. However, this feature is indeed very dangerous (there is no option to delete the entire disk in Windows Exploerer). Could you please remove this feature to prevent noobs from destroying their computers?
Firstly, thanks for the report.
This feature belongs to the File Manager plugin - Code::Blocks. I have never used this plugin expect for file browse.
Indeed, remove the whole drive is very dangerous, so, the proposed method could be:
Check to see the current folder is a root folder of a hard disk drives, if it is, just prompt a dialog and say "you are not allowed to delete the drive".
Any ideas?
Removing the Delete option if the root folder is selected should be enough:
Probably the "Move to..." menu item should also be guarded.
Fixed in [r13572], thank you.
Related
Commit: [r13572]
Thank you.