Open maksqwe opened 10 years ago
hmm weird. In msvc12 "timeval" is defined in "winsock.h", which is included in "ftplib.cpp". In an msvc11 environment "winsock.h" does not contain a "timeval" definition?
When I tried compile using msvc11 I got this error. MSDN says that "winsock2.h" is necessary for 'timeval'. Now i checked "winsock.h"(msvc11) and really it contain "timeval" definition. But anyway ftplib.h require include "winsock.h" because of
struct ftphandle {
char *cput,*cget;
int handle;
int cavail,cleft;
char *buf;
int dir;
ftphandle *ctrl;
int cmode;
struct timeval idletime; // <===
}
Sorry for my bad English.
"error C2079: 'ftphandle::idletime' uses undefined struct 'timeval'"
struct 'timeval' defined in "winsock2.h": http://msdn.microsoft.com/en-us/library/windows/desktop/ms740560%28v=vs.85%29.aspx
fix: