summaryrefslogtreecommitdiffstats
path: root/contrib/tar/src
Commit message (Collapse)AuthorAgeFilesLines
* Fix an annoying bug in tar. When it converted 'tar zcf' to 'tar -z -c -f'peter2003-07-241-1/+4
| | | | | | | | it forgot to null terminate the new argv[] array. If you mixed this with $TAR_OPTIONS, phkmalloc and a whole bunch of other variables, you could end up with a segfault. This isn't strictly a phkmalloc victory since tar walks off the end of an array rather than use uninitialized malloc memory, but phkmalloc makes it easier to provoke.
* Centralize _PATH_* definitions.obrien2003-05-051-1/+7
| | | | Submitted by: Tim Kientzle <kientzle@acm.org> (embellished by me)
* Fix security bug in contains_dot_dot routine.sobomax2002-10-192-1/+17
| | | | | | | PR: 43575 Submitted by: Brett Glass <brett@lariat.org> X-MFC after: immediately
* Don't kill itself in --fast-read mode if there is no decompressor started.sobomax2002-10-091-1/+1
| | | | | | | Reported by: Gordon Tetlow <gordont@gnf.org> Submitted by: tjr MFC after: 1 week (along with other --fast-read changes)
* Further improve --fast-read mode - when reading archive from stdin ensure thatsobomax2002-10-021-2/+9
| | | | | | | | SIGTERM we are sending to decompressor when there is nothing left to do is actually delivered to decompressor, not to the another copy of tar, which does unblocking. MFC after: 2 weeks
* In the --fast-read mode send SIGTERM to decompressor once we have extractedsobomax2002-09-091-6/+10
| | | | | | | | | | all files we have been asked for. This vastly improves performance of pkg_add(1), because usually it only extract +CONTENTS file in --fast-read mode, checks it and only then extracts full content of tarball in normal mode. Without this patch, it have had to decompress the tarball twice, effectively doubling consumed CPU time. MFC after: 1 week
* Move even closer to matching behaviour of our old tar(1) wrt preservingsobomax2002-08-011-1/+4
| | | | | | | | | | modes of extracted files. This effectively disables special threating of uid 0 for mode-preserving purposes and should fix problems with pkg_add(1) and probably other things when extracting files/dirs with sticky mode bits set. Pointed out by: bde MFC in: 2 weeks
* Fix another POLA breakage in a new tar: in diff mode presence of filesobomax2002-07-031-3/+7
| | | | | | | in the archive, but its absence in the file system should be reported as difference, not as error. Reported by: bde
* When we are extracting directory with --unlink option and the directorysobomax2002-07-031-2/+6
| | | | | | | already exists don't spew bogus "Cannot unlink" error and exit with non-zero code. Reported by: bde
* Disabling automatic --same-owner option when running as uid 0 along withsobomax2002-06-071-1/+1
| | | | | | | the --same-permissions was an overkill, so put it back. This is consistent with what our old tar did. Suggested by: dillon
* IMO it was a quite ugly idea that if we are running as uid 0 then we cansobomax2002-06-071-0/+4
| | | | | | | safely ignore current umask(2) and assume that permissions should be set right like in the archive. Not only it violates POLA, but introduces huge potential security vulnerability, particularly for ports, where many popular archives come with 777 files and dirs.
* Move patches into the src/contrib/tar.sobomax2002-06-049-34/+117
| | | | | Requested by: ps Reviewed by: md5(1)
* Virgin import (trimmed) of GNU Tar version 1.13.25.sobomax2002-06-0419-0/+13691
OpenPOWER on IntegriCloud