mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-17 10:52:46 +00:00
Convert custom HeadSpin integer types to standard types from stdint.h
This commit is contained in:
@ -62,8 +62,8 @@ struct IniChangeFile;
|
||||
struct IniChangeReg {
|
||||
LINK(IniChangeReg) fLink;
|
||||
FIniFileChangeCallback fNotify;
|
||||
qword fLastWriteTime;
|
||||
wchar fFileName[MAX_PATH];
|
||||
uint64_t fLastWriteTime;
|
||||
wchar_t fFileName[MAX_PATH];
|
||||
};
|
||||
|
||||
static CLock s_lock;
|
||||
@ -73,7 +73,7 @@ static HANDLE s_thread;
|
||||
static HANDLE s_change;
|
||||
static bool s_running;
|
||||
static IniChangeReg * s_dispatch;
|
||||
static wchar s_directory[MAX_PATH];
|
||||
static wchar_t s_directory[MAX_PATH];
|
||||
static LISTDECL(IniChangeReg, fLink) s_callbacks;
|
||||
|
||||
|
||||
@ -84,13 +84,13 @@ static LISTDECL(IniChangeReg, fLink) s_callbacks;
|
||||
***/
|
||||
|
||||
//===========================================================================
|
||||
static qword GetFileTimestamp (const wchar fileName[]) {
|
||||
static uint64_t GetFileTimestamp (const wchar_t fileName[]) {
|
||||
HANDLE find;
|
||||
WIN32_FIND_DATAW fd;
|
||||
qword lastWriteTime;
|
||||
uint64_t lastWriteTime;
|
||||
if (INVALID_HANDLE_VALUE != (find = FindFirstFileW(fileName, &fd))) {
|
||||
COMPILER_ASSERT(sizeof(lastWriteTime) == sizeof(fd.ftLastWriteTime));
|
||||
lastWriteTime = * (const qword *) &fd.ftLastWriteTime;
|
||||
lastWriteTime = * (const uint64_t *) &fd.ftLastWriteTime;
|
||||
FindClose(find);
|
||||
}
|
||||
else {
|
||||
@ -109,7 +109,7 @@ static void ChangeDispatch_WL (IniChangeReg * marker) {
|
||||
|
||||
// If the file record time matches the file data time
|
||||
// then there's no need to reprocess the callbacks
|
||||
qword lastWriteTime = GetFileTimestamp(s_dispatch->fFileName);
|
||||
uint64_t lastWriteTime = GetFileTimestamp(s_dispatch->fFileName);
|
||||
if (s_dispatch->fLastWriteTime == lastWriteTime)
|
||||
continue;
|
||||
s_dispatch->fLastWriteTime = lastWriteTime;
|
||||
@ -212,7 +212,7 @@ static unsigned THREADCALL IniSrvThreadProc (AsyncThread * thread) {
|
||||
***/
|
||||
|
||||
//===========================================================================
|
||||
void IniChangeInitialize (const wchar dir[]) {
|
||||
void IniChangeInitialize (const wchar_t dir[]) {
|
||||
ASSERT(!s_running);
|
||||
s_running = true;
|
||||
|
||||
@ -311,7 +311,7 @@ void IniChangeDestroy () {
|
||||
|
||||
//===========================================================================
|
||||
void IniChangeAdd (
|
||||
const wchar fileName[],
|
||||
const wchar_t fileName[],
|
||||
FIniFileChangeCallback callback,
|
||||
IniChangeReg ** changePtr
|
||||
) {
|
||||
|
@ -92,7 +92,7 @@ AUTO_INIT_FUNC(InitSrvRightsIni) {
|
||||
}
|
||||
|
||||
//============================================================================
|
||||
static EServerRights GetServerRightsFromString(const wchar string[]) {
|
||||
static EServerRights GetServerRightsFromString(const wchar_t string[]) {
|
||||
if (StrCmpI(string, L"Server") == 0)
|
||||
return kSrvRightsServer;
|
||||
else if (StrCmpI(string, L"Basic") == 0)
|
||||
@ -173,7 +173,7 @@ void SrvIniParseServerRights (Ini * ini) {
|
||||
|
||||
// add ini file address blocks
|
||||
while (value) {
|
||||
wchar valStr[20];
|
||||
wchar_t valStr[20];
|
||||
NetAddressNode start;
|
||||
NetAddressNode end;
|
||||
EServerRights rights;
|
||||
|
Reference in New Issue
Block a user