Update dircache startcluster at file close when writing. Fixes bug when creating small files (dircache startcluster remains 0 because fat write doesn't occur until close).

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9950 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Hardeep Sidhu 2006-05-16 06:53:41 +00:00
parent ca916145f9
commit 2436dbabe7

View file

@ -249,6 +249,9 @@ int close(int fd)
rc = fsync(fd);
if (rc < 0)
return rc * 10 - 3;
#ifdef HAVE_DIRCACHE
dircache_update_filesize(fd, file->size, file->fatfile.firstcluster);
#endif
}
file->busy = false;