mdbx-windows: minor simplify MDBX_srwlock.

Change-Id: I1db8e7dab2a3c764fdbe64923cfaab238eacc77e
This commit is contained in:
Leonid Yuriev 2018-10-18 10:33:15 +03:00
parent ecf214ca04
commit f93cca3d14

View File

@ -593,14 +593,12 @@ int mdbx_rpid_set(MDBX_env *env);
int mdbx_rpid_clear(MDBX_env *env); int mdbx_rpid_clear(MDBX_env *env);
#if defined(_WIN32) || defined(_WIN64) #if defined(_WIN32) || defined(_WIN64)
typedef struct MDBX_srwlock { typedef union MDBX_srwlock {
union { struct {
struct { long volatile readerCount;
long volatile readerCount; long volatile writerCount;
long volatile writerCount;
};
RTL_SRWLOCK native;
}; };
RTL_SRWLOCK native;
} MDBX_srwlock; } MDBX_srwlock;
typedef void(WINAPI *MDBX_srwlock_function)(MDBX_srwlock *); typedef void(WINAPI *MDBX_srwlock_function)(MDBX_srwlock *);