#include <libutil.h>
#include <stdio.h>
#include <stdlib.h>
+#include <unistd.h>
#include "pwupd.h"
}
if (gr_copy(pfd, tfd, gr, old_gr) == -1) {
gr_fini();
+ close(tfd);
err(1, "gr_copy()");
}
+ close(tfd);
if (gr_mkdb() == -1) {
gr_fini();
err(1, "gr_mkdb()");