|
-
February 20th, 2009, 03:22 PM
#16
Re: memory leak in my memset usage?
 Originally Posted by lab1
Code:
#include <winsohck2.h>
#pragma comment(lib,"ws2_32.lib")
int main()
{
WSADATA wsaData = {0};
WSAStartup(MAKEWORD(2, 2), &wsaData);
int _socket = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP);
closesocket(_socket);
WSACleanup();
}
There is no memory leaks in this code.
The "scan the heap for memory leaks" doesn't matter until the main() returns.
Last edited by VictorN; February 20th, 2009 at 03:40 PM.
Victor Nijegorodov
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|