Avoid a memory leak on the error code path.

edge.strict_endians
uvman 2006-10-30 13:43:09 +00:00
parent 22108e36a1
commit 3e3196133c
1 changed files with 3 additions and 1 deletions

View File

@ -1376,10 +1376,12 @@ err_out:
ntfs_log_perror("Failed to open SD (0x50) attribute of "
" inode 0x%llx. Run chkdsk.\n",
(unsigned long long)ni->mft_no);
else if (ntfs_attr_rm(na))
else if (ntfs_attr_rm(na)) {
ntfs_log_perror("Failed to remove SD (0x50) attribute "
"of inode 0x%llx. Run chkdsk.\n",
(unsigned long long)ni->mft_no);
ntfs_attr_close(na);
}
}
if (rollback_data) {
ntfs_attr *na;