Replace test scrips with nand and nor versions
[yaffs2.git] / direct / yaffsfs.c
index 5461a48b397edb6fba64afa1d96c2a43dde1e3ec..a0961904ef1def831117843b58edb0767587d0c1 100644 (file)
@@ -24,7 +24,7 @@
 #endif
 
 
-const char *yaffsfs_c_version="$Id: yaffsfs.c,v 1.22 2008-08-19 23:14:22 charles Exp $";
+const char *yaffsfs_c_version="$Id: yaffsfs.c,v 1.24 2008-11-11 01:47:46 charles Exp $";
 
 // configurationList is the list of devices that are supported
 static yaffsfs_DeviceConfiguration *yaffsfs_configurationList;
@@ -489,7 +489,7 @@ int yaffs_open(const YCHAR *path, int oflag, int mode)
                        // Check if the object is already in use
                        alreadyOpen = alreadyExclusive = 0;
 
-                       for(i = 0; i <= YAFFSFS_N_HANDLES; i++)
+                       for(i = 0; i < YAFFSFS_N_HANDLES; i++)
                        {
 
                                if(i != handle &&
@@ -1284,7 +1284,7 @@ int yaffs_set_wince_times(int fd,
 
 static int yaffsfs_DoChMod(yaffs_Object *obj,mode_t mode)
 {
-       int result;
+       int result = -1;
 
        if(obj)
        {