From 7d6a8f2767e715b6a11074669c157f29f9b3254d Mon Sep 17 00:00:00 2001 From: Yura Pakhuchiy Date: Wed, 5 Sep 2007 21:00:16 +0300 Subject: [PATCH] ntfs_ie_add(): cleanup (Szaka) --- libntfs/index.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libntfs/index.c b/libntfs/index.c index 4d1300c4..2a5e6bd0 100644 --- a/libntfs/index.c +++ b/libntfs/index.c @@ -1406,13 +1406,16 @@ static int ntfs_ib_split(ntfs_index_context *icx, INDEX_BLOCK *ib) static int ntfs_ie_add(ntfs_index_context *icx, INDEX_ENTRY *ie) { - char *fn; INDEX_HEADER *ih; int allocated_size, new_size; int ret = STATUS_ERROR; +#ifdef DEBUG + char *fn; fn = ntfs_ie_filename_get(ie); ntfs_log_trace("file: '%s'\n", fn); + free(fn); +#endif while (1) { if (!ntfs_index_lookup(&ie->key, le16_to_cpu(ie->key_length), @@ -1457,7 +1460,6 @@ static int ntfs_ie_add(ntfs_index_context *icx, INDEX_ENTRY *ie) ret = STATUS_OK; err_out: - free(fn); ntfs_log_trace("%s\n", ret ? "Failed" : "Done"); return ret; }