gpt4 book ai didi

c++ - WOW64:从 32 位进程获取 x64 %CommonProgramFiles%

转载 作者:可可西里 更新时间:2023-11-01 18:09:52 27 4
gpt4 key购买 nike

我尝试过的查询:ExpandEnvironmentStrings("%COMMONPROGRAMFILES%")GetSpecialPath(CSIDL_PROGRAM_FILES_COMMON)

我的 32 位应用程序中的所有内容都解析为(通常)c:\\Program Files (x86)\\Common Files。我需要检查(通常)安装在 64 位应用程序的 c:\\Program Files\\Common Files 下的文件版本。

最佳答案

在 64 位操作系统上,ProgramW6432 环境变量指向 c:\program files。英文版 Windows 上的 32 位应用的完整列表:

  • ProgramFiles => c:\程序文件 (x86)
  • ProgramFiles(x86) => c:\program files (x86)
  • ProgramW6432 => c:\程序文件
  • CommonProgramFiles => c:\program files (x86)\common files
  • CommonProgramFiles(x86) => c:\program files (x86)\common files
  • CommonProgramW6432 => c:\program files\common files

提醒一下:该文件夹不应包含 32 位程序感兴趣的任何内容。从技术上讲。当心文件系统重定向器,它将文件请求从 c:\program files 重定向到 c:\program files (x86)。如果您真的想访问该目录中的文件,则必须使用 Wow64DisableWow64FsRedirection()。

关于c++ - WOW64:从 32 位进程获取 x64 %CommonProgramFiles%,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2539724/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com