Fixed some compiler warnings in WINCE only sections when using the MSVC compiler.

FossilOrigin-Name: 1f0a93e17d6291268da909699ce1a5a7619ae637
This commit is contained in:
shane 2009-08-12 15:34:02 +00:00
parent 2210dcc60d
commit d87873d19b
6 changed files with 34 additions and 29 deletions

0
configure vendored Executable file → Normal file
View File

View File

@ -1,8 +1,5 @@
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
C Make\ssure\sthe\slarge-file\ssupport\smacros\soccur\sfirst\sin\ssqliteInt.h.\nFix\sfor\sCVSTrac\sticket\s#4022.
D 2009-08-12T11:45:41
C Fixed\ssome\scompiler\swarnings\sin\sWINCE\sonly\ssections\swhen\susing\sthe\sMSVC\scompiler.
D 2009-08-12T15:34:03
F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0
F Makefile.in c606c9b502dfde3b9c3b2d23ed49f3737829693b
F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
@ -21,7 +18,7 @@ F art/powered_by_sqlite.gif 7fbcd7d3675391fd3d21672c14c05f5999eb60d1
F config.guess 226d9a188c6196f3033ffc651cbc9dcee1a42977
F config.h.in 868fdb48c028421a203470e15c69ada15b9ba673
F config.sub 9ebe4c3b3dab6431ece34f16828b594fb420da55
F configure 486c870218ec915bd8edfece7109b6c864e82a5a x
F configure 486c870218ec915bd8edfece7109b6c864e82a5a
F configure.ac 14740970ddb674d92a9f5da89083dff1179014ff
F contrib/sqlitecon.tcl 210a913ad63f9f991070821e599d600bd913e0ad
F doc/lemon.html f0f682f50210928c07e562621c3b7e8ab912a538
@ -149,7 +146,7 @@ F src/os.h fa3f4aa0119ff721a2da4b47ffd74406ac864c05
F src/os_common.h 8c61457df58f1a4bd5f5adc3e90e01b37bf7afbc
F src/os_os2.c bed77dc26e3a95ce4a204936b9a1ca6fe612fcc5
F src/os_unix.c cdb2a08b9ce4aa13b3f7b91d4dd60fb48be9f56a
F src/os_win.c 79bb3c59d60bc6faadd379cf036c132fa545d7d6
F src/os_win.c 6de69d8f51d4bf35484e9be1588089a61569491f
F src/pager.c a47be286477ed6c7b9a342dd53d4e4043f29d8c2
F src/pager.h 11852d044c86cf5a9d6e34171fb0c4fcf1f6265f
F src/parse.y 6c42631e72a3d14cde2bee85e79409066066d3df
@ -503,7 +500,7 @@ F test/permutations.test 1ce2874df8fec876d0b963c7a3ef61c4e9df8827
F test/pragma.test a35b0be36542477183168cdb8b743f5c0d883c4d
F test/pragma2.test 5364893491b9231dd170e3459bfc2e2342658b47
F test/printf.test 47e9e5bbec8509023479d54ceb71c9d05a95308a
F test/progress.test 5b075c3c790c7b2a61419bc199db87aaf48b8301 x
F test/progress.test 5b075c3c790c7b2a61419bc199db87aaf48b8301
F test/ptrchng.test ef1aa72d6cf35a2bbd0869a649b744e9d84977fc
F test/quick.test f6eb3a98643b5856626ad38933334762270db129
F test/quote.test 215897dbe8de1a6f701265836d6601cc6ed103e6
@ -727,7 +724,7 @@ F tool/genfkey.test 405a43d54f1646bfaa7a84b03bb959aef62a3a49
F tool/lemon.c 0eb9829c494dfcea449de36ad677efe7f0742801
F tool/lempar.c 2ed70b3fc896a47e07fedfe543324f008f53d223
F tool/mkkeywordhash.c 511a848b2ac7a3d93f36adc1e1086b4c5741224b
F tool/mkopts.tcl 66ac10d240cc6e86abd37dc908d50382f84ff46e x
F tool/mkopts.tcl 66ac10d240cc6e86abd37dc908d50382f84ff46e
F tool/mkspeedsql.tcl a1a334d288f7adfe6e996f2e712becf076745c97
F tool/mksqlite3c.tcl b790a58c9971e3ace07e92cab5604fec8849fa23
F tool/mksqlite3h.tcl d27b76db9639f17c24dcd24e803c9e5e8f9eac23
@ -745,14 +742,7 @@ F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff
F tool/speedtest8.c 2902c46588c40b55661e471d7a86e4dd71a18224
F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
F tool/vdbe-compress.tcl 672f81d693a03f80f5ae60bfefacd8a349e76746
P 7f4810747b0864981f27edbd504bfab2efea1e3c
R 680830094bf2c6c0483804abaedb784f
U drh
Z 0e78fd18dba7cf28c119ae9acf373d8c
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Darwin)
iD8DBQFKgqtqoxKgR168RlERAk55AJ4qz1L4Doc0PwV2LXMDYvvmWnroBwCfeyVW
Gogu2M2hJv/I58I80flxUqA=
=Ha82
-----END PGP SIGNATURE-----
P b0848925babde5241aefe0a117ebb10299c94a15
R 85d8bc88106b78c6b602120dcf0a8f49
U shane
Z 4619ac16a1c5a72371d086ffe5b2d550

View File

@ -1 +1 @@
b0848925babde5241aefe0a117ebb10299c94a15
1f0a93e17d6291268da909699ce1a5a7619ae637

View File

@ -309,8 +309,8 @@ struct tm *__cdecl localtime(const time_t *t)
sqlite3_int64 t64;
t64 = *t;
t64 = (t64 + 11644473600)*10000000;
uTm.dwLowDateTime = t64 & 0xFFFFFFFF;
uTm.dwHighDateTime= t64 >> 32;
uTm.dwLowDateTime = (DWORD)(t64 & 0xFFFFFFFF);
uTm.dwHighDateTime= (DWORD)(t64 >> 32);
FileTimeToLocalFileTime(&uTm,&lTm);
FileTimeToSystemTime(&lTm,&pTm);
y.tm_year = pTm.wYear - 1900;
@ -330,7 +330,7 @@ struct tm *__cdecl localtime(const time_t *t)
#define UnlockFile(a,b,c,d,e) winceUnlockFile(&a, b, c, d, e)
#define LockFileEx(a,b,c,d,e,f) winceLockFileEx(&a, b, c, d, e, f)
#define HANDLE_TO_WINFILE(a) (winFile*)&((char*)a)[-offsetof(winFile,h)]
#define HANDLE_TO_WINFILE(a) (winFile*)&((char*)a)[-(int)offsetof(winFile,h)]
/*
** Acquire a lock on the handle h
@ -469,6 +469,9 @@ static BOOL winceLockFile(
winFile *pFile = HANDLE_TO_WINFILE(phFile);
BOOL bReturn = FALSE;
UNUSED_PARAMETER(dwFileOffsetHigh);
UNUSED_PARAMETER(nNumberOfBytesToLockHigh);
if (!pFile->hMutex) return TRUE;
winceMutexAcquire(pFile->hMutex);
@ -530,14 +533,17 @@ static BOOL winceUnlockFile(
winFile *pFile = HANDLE_TO_WINFILE(phFile);
BOOL bReturn = FALSE;
UNUSED_PARAMETER(dwFileOffsetHigh);
UNUSED_PARAMETER(nNumberOfBytesToUnlockHigh);
if (!pFile->hMutex) return TRUE;
winceMutexAcquire(pFile->hMutex);
/* Releasing a reader lock or an exclusive lock */
if (dwFileOffsetLow >= SHARED_FIRST &&
dwFileOffsetLow < SHARED_FIRST + SHARED_SIZE){
if (dwFileOffsetLow == SHARED_FIRST){
/* Did we have an exclusive lock? */
if (pFile->local.bExclusive){
assert(nNumberOfBytesToUnlockLow == SHARED_SIZE);
pFile->local.bExclusive = FALSE;
pFile->shared->bExclusive = FALSE;
bReturn = TRUE;
@ -545,6 +551,7 @@ static BOOL winceUnlockFile(
/* Did we just have a reader lock? */
else if (pFile->local.nReaders){
assert(nNumberOfBytesToUnlockLow == 1);
pFile->local.nReaders --;
if (pFile->local.nReaders == 0)
{
@ -586,6 +593,9 @@ static BOOL winceLockFileEx(
DWORD nNumberOfBytesToLockHigh,
LPOVERLAPPED lpOverlapped
){
UNUSED_PARAMETER(dwReserved);
UNUSED_PARAMETER(nNumberOfBytesToLockHigh);
/* If the caller wants a shared read lock, forward this call
** to winceLockFile */
if (lpOverlapped->Offset == SHARED_FIRST &&
@ -1592,9 +1602,15 @@ static int getSectorSize(
const char *zRelative /* UTF-8 file name */
){
DWORD bytesPerSector = SQLITE_DEFAULT_SECTOR_SIZE;
/* GetDiskFreeSpace is not supported under WINCE */
#if SQLITE_OS_WINCE
UNUSED_PARAMETER(pVfs);
UNUSED_PARAMETER(zRelative);
#else
char zFullpath[MAX_PATH+1];
int rc;
DWORD dwRet = 0, dwDummy;
DWORD dwRet = 0;
DWORD dwDummy;
/*
** We need to get the full path name of the file
@ -1620,7 +1636,6 @@ static int getSectorSize(
&bytesPerSector,
&dwDummy,
&dwDummy);
#if SQLITE_OS_WINCE==0
}else{
/* trim path to just drive reference */
CHAR *p = (CHAR *)zConverted;
@ -1635,7 +1650,6 @@ static int getSectorSize(
&bytesPerSector,
&dwDummy,
&dwDummy);
#endif
}
free(zConverted);
}
@ -1643,6 +1657,7 @@ static int getSectorSize(
bytesPerSector = SQLITE_DEFAULT_SECTOR_SIZE;
}
}
#endif
return (int) bytesPerSector;
}

0
test/progress.test Executable file → Normal file
View File

0
tool/mkopts.tcl Executable file → Normal file
View File