上次在MSDN论坛上看见一个网友问ZeroMemory的用处,问题里面说他在内存上分配了一个变量,但是在使用它调用一个函数的时候,系统报告Access Violation异常,但是加上ZeroMemory以后,就运行正常了,因此他想知道ZeroMemory的用处。
// 使用未初始化变量.cpp : Defines the entry point for the console application.
#include "stdafx.h" #include <windows.h>
int _tmain(int argc, _TCHAR* argv[]) { STARTUPINFO info; |