Windows 32位GAS汇编调用fopen:寻找fopen/fwrite所在DLL
32位Windows下
_fopen与_fwrite的承载DLL说明 - 32位Windows系统中,
_fopen和_fwrite这类标准C库函数,核心承载DLL是msvcrt.dll,绝大多数32位Windows版本(包括XP、7等)的该库都导出了这两个带下划线的函数; - 对于较新的32位Windows系统(如Windows 10及以上),部分标准C库函数也会被放在
ucrtbase.dll中,同样可以找到_fopen和_fwrite的导出项; - 你可以用系统自带的
dumpbin工具(需借助Visual Studio命令行工具集)验证:执行dumpbin /exports msvcrt.dll或dumpbin /exports ucrtbase.dll,查看输出中是否包含目标函数名; - 加载优先级建议:先尝试
LoadLibrary("msvcrt.dll"),若无法找到目标函数,再尝试加载ucrtbase.dll。
内容的提问来源于stack exchange,提问作者shawnixer
相关产品推荐
相关产品推荐

