ntfs_attr_pclose: fix uninitialized variable which may lead to an infinite

loop on a read-only file system (Erik Larsson, Jean-Pierre Andre)
This commit is contained in:
szaka 2010-01-15 19:32:44 +00:00
parent 670d72620d
commit c32f2a4f59

View File

@ -1883,6 +1883,7 @@ int ntfs_attr_pclose(ntfs_attr *na)
} }
retry: retry:
written = 0;
if (!NVolReadOnly(vol)) { if (!NVolReadOnly(vol)) {
written = ntfs_compressed_close(na, rl, ofs); written = ntfs_compressed_close(na, rl, ofs);