perf data: Close all files in close_dir()
[linux-2.6-microblaze.git] / tools / perf / util / data.c
index a9c102e..f5d260b 100644 (file)
@@ -20,7 +20,7 @@
 
 static void close_dir(struct perf_data_file *files, int nr)
 {
-       while (--nr >= 1) {
+       while (--nr >= 0) {
                close(files[nr].fd);
                zfree(&files[nr].path);
        }