Old fix from Robert Crowe <bob@speakez.com> that has been sitting in

my mailbox since early last year. Fixes a problem with running out of
fds (by hitting the limit or whatever) when ar is given a long list of
objects. The fix was to add a missing close().

Submitted by:	Robert Crowe <bob@speakez.com>
This commit is contained in:
David Greenman 1995-01-09 04:50:30 +00:00
parent 10824ac8f3
commit cfc22f9026
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=5447

View File

@ -102,8 +102,10 @@ replace(argv)
goto useold;
}
(void)fstat(sfd, &sb);
if (options & AR_U && sb.st_mtime <= chdr.date)
if (options & AR_U && sb.st_mtime <= chdr.date) {
(void) close(sfd);
goto useold;
}
if (options & AR_V)
(void)printf("r - %s\n", file);