You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MB-41209: Use specific 'Winsock2.h' header for timeval
When compiling under MSVC with 'WIN32_LEAN_AND_MEAN' defined (to avoid
symbol collisions with glog / reduce number of unnecessary headers
included), forestdb fails to compile with the following error:
..\forestdb\utils\gettimeofday_vs.cc(25): error C2027: use of undefined type 'timeval'
forestdb\utils\gettimeofday_vs.h(17): note: see declaration of 'timeval'
The issue is that gettimeofday_vs.h & time_utils.h includes Windows.h,
which will only include the necessary header for 'timeval'
(Winsock2.h) if WIN32_LEAN_AND_MEAN is not defined.
Fix this by simply including the necessary Winsock2.h header directly.
Change-Id: I01338d47b2943e3646e959f19bf6118428ce0e4d
Reviewed-on: http://review.couchbase.org/c/forestdb/+/135517
Well-Formed: Build Bot <[email protected]>
Reviewed-by: Trond Norbye <[email protected]>
Tested-by: Build Bot <[email protected]>
0 commit comments