|
-
June 15th, 2001, 11:32 AM
#1
fatal error LNK1136: invalid or corrupt file
Hi,
i am trying to do socket programming in vc++ under windows 2000.
i had included <windows.h> in my program..when i build my project i am getting the the following exception..
C:\Program Files\Microsoft Visual Studio\VC98\LIB\winsock.lib : fatal error LNK1136: invalid or corrupt file
could any body tell me the reason.
Thanks in advance..
--sreeny
-
June 15th, 2001, 11:44 PM
#2
Re: fatal error LNK1136: invalid or corrupt file
Try this :
/* Prevent inclusion of winsock.h in windows.h */
#ifndef _WINSOCKAPI_
#define _WINSOCKAPI_
#endif
#include <windows.h>
and link ws2_32.lib. No winsock.lib. This library doesn't exist.
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
|