Code

Merge branch 'master' into db/fetch-pack
[git.git] / diff.c
diff --git a/diff.c b/diff.c
index ab575191d11801f023655fe6cf718bfa5fa04c9b..6648e015213913e693b4450230a5a0896a21f7a0 100644 (file)
--- a/diff.c
+++ b/diff.c
@@ -1627,7 +1627,7 @@ int diff_populate_filespec(struct diff_filespec *s, int size_only)
        return 0;
 }
 
-void diff_free_filespec_data(struct diff_filespec *s)
+void diff_free_filespec_blob(struct diff_filespec *s)
 {
        if (s->should_free)
                free(s->data);
@@ -1638,6 +1638,11 @@ void diff_free_filespec_data(struct diff_filespec *s)
                s->should_free = s->should_munmap = 0;
                s->data = NULL;
        }
+}
+
+void diff_free_filespec_data(struct diff_filespec *s)
+{
+       diff_free_filespec_blob(s);
        free(s->cnt_data);
        s->cnt_data = NULL;
 }