AttachConsole 的真正最低版本要求是什么? [英] What are real minimum version requirements for AttachConsole?

查看:22
本文介绍了AttachConsole 的真正最低版本要求是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在线 PSDK 文档状态 5.1 (WinXP):

Online PSDK documentation states 5.1 (WinXP):

要编译使用此函数的应用程序,请定义 _WIN32_WINNT为 0x0501 或更高版本.有关详细信息,请参阅使用 Windows标题.

To compile an application that uses this function, define _WIN32_WINNT as 0x0501 or later. For more information, see Using the Windows Headers.

支持的最低客户端:Windows XP [仅限桌面应用]

Minimum supported client: Windows XP [desktop apps only]

支持的最低服务器:Windows Server 2003 [仅限桌面应用]

Minimum supported server: Windows Server 2003 [desktop apps only]


PSDK doc 的较旧本地副本模糊地不同意上述内容,并尝试声明 5.0 (Win2k) 或 5.1:


Older local copy of PSDK doc vaguely disagrees with above, and attempts to state either 5.0 (Win2k) or 5.1:

要编译使用此函数的应用程序,请定义 _WIN32_WINNT为 0x0500 或更高版本.有关详细信息,请参阅使用 SDK 标头.

To compile an application that uses this function, define _WIN32_WINNT as 0x0500 or later. For more information, see Using the SDK Headers.

客户端:需要 Windows Vista 或 Windows XP.
服务器:需要 Windows 服务器Longhorn";或 Windows Server 2003.

Client: Requires Windows Vista or Windows XP.
Server: Requires Windows Server "Longhorn" or Windows Server 2003.


最后,PSDK 标头(也相当旧)正在提倡 Win2k:


Finally, PSDK headers (rather old too) are advocating for Win2k:

#if(_WIN32_WINNT >= 0x0500)
WINBASEAPI
BOOL
WINAPI
AttachConsole(
    __in DWORD dwProcessId);

#define ATTACH_PARENT_PROCESS ((DWORD)-1)

#endif /* _WIN32_WINNT >= 0x0500 */


我没有比 WinXP SP3 更早的东西来检查 kernel32.dll 导出目录,所以请告诉我真正支持的最低版本是什么,5.0还是5.1?


I dont have anything older than WinXP SP3 handy to examine kernel32.dll export directory, so please enlighten me what is minimum supported version for real, 5.0 or 5.1?

推荐答案

所需的最低客户端是 Windows 2000 (0x0500).信息不匹配的原因是 MSDN 得到了更新.根据更新是在 Windows 2000 的 EOL 之前还是之后发生的,客户端要求列出 Windows XP 或 Windows 2000.

The minimum required client is Windows 2000 (0x0500). The reason for the mismatching information is, that the MSDN gets updated. Depending on whether the update happened before or after the EOL of Windows 2000, the client requirements either list Windows XP or Windows 2000.

如果有疑问,头文件是权威的.Windows 8.0 SDK 在 AttachConsole 的声明周围仍然有 #if(_WIN32_WINNT >= 0x0500).

If in doubt, the header files are authoritative. The Windows 8.0 SDK still has #if(_WIN32_WINNT >= 0x0500) around the declaration for AttachConsole.

这篇关于AttachConsole 的真正最低版本要求是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆