aboutsummaryrefslogtreecommitdiff
path: root/src/os_unix.c
diff options
context:
space:
mode:
authorrse <rse@noemail.net>2007-09-20 08:38:14 +0000
committerrse <rse@noemail.net>2007-09-20 08:38:14 +0000
commit25c0d1a18a688a9436e500a8313fcd5c85696e59 (patch)
tree61c04213fbe419464cc0d14954c24cb0d869e09c /src/os_unix.c
parent78d1ef1a51a88c513d5c771cd8315c9aa84e6200 (diff)
downloadsqlite-25c0d1a18a688a9436e500a8313fcd5c85696e59.tar.gz
sqlite-25c0d1a18a688a9436e500a8313fcd5c85696e59.zip
The code is correct as it contains an assert(3) in the "default" switch
case, but GCC 4.3 is not able to detect this and instead complains with "warning: 'amode' may be used uninitialized in this function". Hence, although the assert(3) already protects the code here, get rid of this compiler warning by doing a simple initialization of the "amode" variable. (CVS 4436) FossilOrigin-Name: 91831ff2922666b39d8f4ba448982c6763030633
Diffstat (limited to 'src/os_unix.c')
-rw-r--r--src/os_unix.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/os_unix.c b/src/os_unix.c
index 2732f58e9..425bdc5f3 100644
--- a/src/os_unix.c
+++ b/src/os_unix.c
@@ -2451,7 +2451,7 @@ static int unixDelete(sqlite3_vfs *pVfs, const char *zPath, int dirSync){
** Otherwise return 0.
*/
static int unixAccess(sqlite3_vfs *pVfs, const char *zPath, int flags){
- int amode;
+ int amode = 0;
switch( flags ){
case SQLITE_ACCESS_EXISTS:
amode = F_OK;