Add missing fts_close() calls
authorFrançois Tigeot <ftigeot@wolfpond.org>
Sat, 3 Dec 2011 08:40:15 +0000 (09:40 +0100)
committerFrançois Tigeot <ftigeot@wolfpond.org>
Sat, 3 Dec 2011 09:28:33 +0000 (10:28 +0100)
sbin/vquota/vquota.c
usr.bin/du/du.c

index f63d28b..c412ca3 100644 (file)
@@ -89,6 +89,7 @@ get_dirsize(char* dirname)
                        size_of_files += p->fts_statp->st_size;
                }
        }
+       fts_close(fts);
 
        printf("%"PRIu64"\n", size_of_files);
        return retval;
index 860cf05..a729ef5 100644 (file)
@@ -279,6 +279,7 @@ main(int argc, char **argv)
                if (p->fts_parent->fts_pointer)
                        savednumber = *(du_number_t *)p->fts_parent->fts_pointer;
        }
+       fts_close(fts);
 
        if (errno)
                err(1, "fts_read");