yaffs Fixed some more bugs in direct/timothy_tests/mirror_tests
authorTimothy Manning <tfhmanning@gmail.com>
Wed, 15 Dec 2010 02:31:57 +0000 (15:31 +1300)
committerTimothy Manning <tfhmanning@gmail.com>
Wed, 15 Dec 2010 02:31:57 +0000 (15:31 +1300)
Signed-off-by: Timothy Manning <tfhmanning@gmail.com>
direct/timothy_tests/mirror_tests/mirror_tests.c

index 88c509f..641ceeb 100644 (file)
@@ -228,6 +228,7 @@ int compare_linux_and_yaffs(void)
                                strcpy(yaffs_file_list[x],yaffs_current_file->d_name);
                        }
                }
+               yaffs_closedir(yaffs_open_dir);
        }
 
        linux_open_dir = opendir(linux_struct.root_path);
@@ -245,6 +246,7 @@ int compare_linux_and_yaffs(void)
                                strcpy(linux_file_list[x],linux_current_file->d_name);
                        }
                }
+               closedir(linux_open_dir);
        }
 
 
@@ -367,7 +369,8 @@ void clean_dir(void)
                                unlink(file);
                        }
                }
-               unlink(linux_struct.root_path);
+               closedir(linux_open_dir);
+               rmdir(linux_struct.root_path);
        }
        
 }