IT技术博客大学习 共学习 共进步

Windows 95 defenses against installers that overwrite a file with an older version

neverland 2026-06-03 09:03:24 累计浏览 4 次
本机暂存

Raymond Chen:

Back in the days of 16-bit Windows, many system components were redistributable, meaning that programs that used those components could include a copy of those system components and install them onto the system as part of the program’s installer.

It was common for program installers to overwrite any file that was in their way, regardless of the existing file’s version number. When these installers ran on Windows 95, the replaced the Windows 95 versions of the components with the Windows 3.1 versions.

Windows 95 worked around this by keeping a backup copy of commonly-overwritten files in a hidden C:\Windows\SYSBCKUP directory. Whenever an installer finished, Windows went and checked whether any of these commonly-overwritten files had indeed been overwritten. If so, and the replacement has a higher version number than the one in the SYSBCKUP directory, then the replacement was copied into the SYSBCKUP directory for safekeeping. Conversely, if the replacement has a lower version number than the one in the SYSBCKUP directory, then the copy from SYSBCKUP was copied on top of the rogue replacement.

An earlier design simply blocked the installer’s attempt to overwrite the file, but this ended up creating more problems.

The way that worked best was to let the installer overwrite anything it wanted and then go back and try to clean up the mess.

建议继续学习

  1. 提升磁盘IO性能的几个技巧 (累计阅读 8,442)
  2. C语言中史上最愚蠢的Bug (累计阅读 8,022)
  3. 哇,让你的DB再快一倍:ext4 vs xfs对比测试 (累计阅读 5,382)
  4. 为什么Linux不需要磁盘碎片整理 (累计阅读 5,280)
  5. 文件明明存在但是file_exists总是返回FALSE (累计阅读 4,960)
  6. 分布式存储Seaweedfs源码分析 (累计阅读 4,647)
  7. php 返回目录下的所有文件名/文件夹类 (累计阅读 4,381)
  8. 使用 sshfs 调用 ssh 服务器上的内容 (累计阅读 4,320)
  9. innodb_flush_method带来的性能影响 (累计阅读 4,281)
  10. linux磁盘管理学习笔记(上) (累计阅读 4,220)