Locking Executing Files: Windows does, Linux doesn't. Why?

前端 未结 8 1544
有刺的猬
有刺的猬 2020-12-04 09:18

I noticed when a file is executed on Windows (.exe or .dll), it is locked and cannot be deleted, moved or modified.

Linux, on the other hand, does not lock executing

8条回答
  •  时光取名叫无心
    2020-12-04 09:57

    Executables are progressively mapped to memory when run. What that means is that portions of the executable are loaded as needed. If the file is swapped out prior to all sections being mapped, it could cause major instability.

提交回复
热议问题