Commit Graph

8503 Commits

Author SHA1 Message Date
Tim Kientzle
a38d1d4c8b bsdtar 2.2.3:
* Implement --use-compress-program using new libarchive feature.
  * Minor portability improvement by adjusting casts used to
    print out uids, gids, and device numbers.

Thanks to: Joerg Sonnenberger for the --use-compress-program implementation.
MFC after: 15 days
2007-05-29 05:39:10 +00:00
Xin LI
2a8e7ac9c8 Add a '-k' flag which is similar with its bzip2(1) counterpart,
meaning that the user wants the input file to be left intact.

Feature request: Ighighi <ighighi gmail.com>
PR:		 bin/103006
MFC after:	 1 month
2007-05-28 08:20:46 +00:00
Ruslan Ermilov
55e1a40108 Update for the 4.21 import (manuals didn't change). 2007-05-25 09:25:05 +00:00
David E. O'Brien
79f6e0e6b4 FreeBSD has <limits.h>. 2007-05-24 22:10:22 +00:00
David E. O'Brien
8cbe72bdb7 Update for the 'file' 4.21 import. 2007-05-24 22:02:49 +00:00
Lukas Ertl
46a3ae64b2 Fix handling of filenames containing whitespace.
PR:      bin/112860
MFC in:  3 days
2007-05-24 18:28:08 +00:00
David E. O'Brien
a90b38c0b1 Update for the 'file' 4.19 import. 2007-05-24 16:14:38 +00:00
Ruslan Ermilov
a688ea13f5 Don't want a stray systrace_args.c in objdir. 2007-05-22 10:36:12 +00:00
Diomidis Spinellis
fdbe5babe4 Increase precision of time values in the process accounting
structure, while maintaining backward compatibility with legacy
file and record formats.
2007-05-22 06:51:38 +00:00
Giorgos Keramidas
42aff2e46d Remove duplicate ' 2' manpage section number.
Submitted by:	 Rui Paulo
MFC after:	 3 days
2007-05-21 20:33:51 +00:00
Tim Kientzle
3b0e49fad9 Mention the formats supported by bsdtar; include an
example that shows how to work with an ISO 9660 image.
2007-05-20 18:23:39 +00:00
Juli Mallett
26cfaf71bb Fix typo. 2007-05-17 00:19:56 +00:00
Juli Mallett
36c5e18daa o) Correct for missing whitespace.
o) We don't need to check if ifp == stdin to give the filename, since we already
   know that ifn will be "stdin" if it is.
2007-05-17 00:18:01 +00:00
Juli Mallett
2fdb65fd82 Fix confusing misindentation of a closing-brace. (It goes with the switch, not
with the while.)
2007-05-17 00:11:58 +00:00
Diomidis Spinellis
e91843d40a Backout revisions 1.16-1.14.
Backwards compatibility with the new acct(5) format will be
implemented through the explicit versioning of acct records,
not through an export/import procedure.
2007-05-14 09:05:22 +00:00
Andre Oppermann
612d21296c 'netstat -A -p tcp' doesn't print the Socket but the Tcpcb pointer in the
first column.
2007-05-13 22:32:32 +00:00
Pav Lucistnik
67a09fffe1 Replace rev. 1.9 with patch from OpenBSD.
Submitted by:	Ray Lai <ray@cyth.net>
Obtained from:	http://www.openbsd.org/cgi-bin/cvsweb/src/usr.bin/tip/acu.c.diff?r1=1.13&r2=1.14
MFC after:	1 week
2007-05-12 23:29:33 +00:00
Pav Lucistnik
bae1345b9d Fix crash when using 'du' capability: NULL return of strpbrk was not handled
PR:		bin/108368
Reported by:	Ivo Hazmuk <ivo@vutbr.cz>
Submitted by:	rdivacky
MFC after:	2 weeks
2007-05-12 13:36:13 +00:00
Pav Lucistnik
0e2dd92370 Expand documentation of -f option
PR:		docs/66265
Submitted by:	Michel Lavondes <fox@vader.aacc.cc.md.us>
MFC after:	1 week
2007-05-12 12:23:40 +00:00
Tim Kientzle
6a955a7506 Set the program return value non-zero if we enounter
an error while skipping the body of an entry during
"tar -t" processing.

Thanks to: Spencer Minear
PR: misc/112521
2007-05-08 15:22:21 +00:00
David Malone
61d8eede29 Cast to intmax_t to print tv_sec in struct timeval.
Avoid shadowing a global variable with a function argument.
Set WARNS to 6.
2007-05-07 12:23:23 +00:00
David Malone
2ffe6bbf0f Use [u]intmax_t to printf unknown integer types.
Make timeprt always allocate memory, to make things a little simpler.
Remove an unused variable.
2007-05-07 12:10:06 +00:00
David Malone
6f62d86388 Make logmsg take const char * arguments.
Set WARNS to 6.
2007-05-07 11:28:01 +00:00
David Malone
e4cedda807 ANSIfy function definitions.
Move some extern declarations to a header file.
Remove an unneeded extern declaration for optarg.
2007-05-07 11:18:30 +00:00
David Malone
bc7e443092 Fix some warnings by making things const, adding missing headers,
removing some unused variables and making a variable unsigned.

MFC after:	3 weeks
2007-05-07 11:01:36 +00:00
David Malone
61f31ed6cf Initialise variable size so that reading stdin works deterministically.
Add missing include.

Default to WARNS=6.
2007-05-03 13:57:19 +00:00
Benjamin Close
d7a1f74bec Add myself
Approved by:	mlaier (mentor)
2007-05-03 11:34:36 +00:00
Colin Percival
c85ac10468 If lstat(2) fails, have bsdtar return a non-zero exit code if the
failed path is one which was specified on the command line.

This is a compromise between the situation prior to revision 1.57
(where a race between tar(1) and rm(1) could cause tar(1) to
spuriously report an error) and the situation after revision 1.57
(where "tar -c /no/such/path" prints a warning but returns with
an exit code of zero).

Inspired by:	rafan
MFC after:	1 week
2007-05-03 04:33:11 +00:00
Andrey A. Chernov
ba174a5e38 Back out all POSIXified *env() changes.
Not because I admit they are technically wrong and not because of bug
reports (I receive nothing). But because I surprisingly meets so
strong opposition and resistance so lost any desire to continue that.

Anyone who interested in POSIX can dig out what changes and how
through cvs diffs.
2007-05-01 16:02:44 +00:00
Andrey A. Chernov
35e4f24d23 limits calls setenv("name=value", "value", 1); which violates POSIX:
"The setenv( ) function shall fail if:
[EINVAL] The name argument is a null pointer, points to an empty string,
or points to a string containing an '=' character."
The fix (like all others in this subject) is backward-compatible.
2007-04-30 20:10:10 +00:00
Andrey A. Chernov
ed4bcacfde env calls setenv("name=value", "value", 1); which violates POSIX:
"The setenv( ) function shall fail if:
[EINVAL] The name argument is a null pointer, points to an empty string,
or points to a string containing an '=' character."
The fix (like all others in this subject) is backward-compatible.
2007-04-30 19:25:00 +00:00
Andrey A. Chernov
8673ed1565 Slightly tune previous fix: free memory if !export 2007-04-30 12:54:02 +00:00
Andrey A. Chernov
9e461e53cc Prepare for upcoming POSIXed putenv() rewrite:
don't free memory after putenv()
2007-04-30 12:51:02 +00:00
Andrey A. Chernov
2efaac818f Prepare for upcoming POSIXed putenv() rewrite:
don't free memory after putenv()
2007-04-30 12:44:04 +00:00
Maxim Konovalov
4063583a62 o Fill the list of icmp types; make its size depend on ICMP_MAXTYPE.
o Print "unknown ICMP" instead of "(null)" if we don't have a description         for a icmp type.

Based on code

Submitted by:	Christoph Weber-Fahr
PR:		misc/112126
MFC after:	2 weeks
2007-04-30 12:27:04 +00:00
Andrey A. Chernov
97e49dd4b5 Eliminate error with -W* strict flags and make putenv() calls conforming to
standard and portable in the same way as f.e. gcc internal portable code does.
2007-04-30 05:14:29 +00:00
David Malone
3e6dcadf52 Change the date for Daylight Savings in the US.
PR:		111102
Submitted by:	Sean Farley <sean-freebsd@farley.org>
Obtained from:	OpenBSD
2007-04-29 20:03:06 +00:00
Brian Somers
2e7b6bff38 Add some more examples. It always takes me a long time to find the S
modifier (-t is ignored without it).

MFC after:	1 week
2007-04-27 18:23:32 +00:00
Marcelo Araujo
e27c581538 - Added entry for Marcelo S. Araujo.
Approved by:	itetcu (comentor)
2007-04-27 18:17:41 +00:00
Tong LIU
e5b725c271 add myself.
Approved by:	delphij (mentor)
2007-04-25 11:59:10 +00:00
Yaroslav Tykhiy
f3aad16b88 Insert explicit space between the output fields to prevent them
from running together when a field overflows.

MFC after:	1 week
2007-04-23 11:43:22 +00:00
Yaroslav Tykhiy
70b36fc0c8 Don't forget to bump document date after changing the content. 2007-04-21 01:22:51 +00:00
Yaroslav Tykhiy
f6703c9c0a Change the semantics of -i (in-place editing) so that it treats
each file independently from other files.  The new semantics are
desired in the most of practical cases, e.g.: delete lines 5-9
from each file.

Keep the previous semantics of -i under a new option, -I, which
uses a single continuous address space covering all files to edit
in-place -- they are too cool to just drop them.

Add regression tests for -i and -I.

Approved by:	dds
Compared with:	GNU sed
Discussed on:	-hackers
MFC after:	2 weeks
2007-04-21 01:21:36 +00:00
Max Khon
45352bae07 Improve logging when -dm is specified: if the node is considered
out-of-date print not only "modified before source" message
but also the path of youngest source.
2007-04-20 06:33:25 +00:00
Max Khon
bc5748e31f When remaking makefiles check that mtime has actually changed.
This fixes infinite restart in the following case:

Makefile: foo

foo: bar
	do-something

Unlike GNU make, BSD make considers "Makefile" node as remade even
if "foo" is up-to-date and was not actually rebuilt.
GNU make does not consider nodes without commands as remade if child nodes
were not actually rebuilt.

Most probably, more proper fix would be to bring BSD make behaviour in-line
with GNU make but this would be more intrusive change.
2007-04-20 06:25:45 +00:00
Diomidis Spinellis
b7dd80b843 Change the export option from -w (write) to -X.
While implementing import it became apparent that write as a mnemonic
is ambiguous and confusing.

MFC after:	8 days
2007-04-18 16:43:21 +00:00
Diomidis Spinellis
3f863a9ae4 Complain on write errors.
Use correct type for write_text.

MFC after:	8 days
2007-04-18 09:39:47 +00:00
Diomidis Spinellis
947ef7f187 Add export capability through the new -w flag.
Discussed in: -arch
MFC after:	8 days
2007-04-18 08:55:54 +00:00
Tim Kientzle
8d36aa79ef Ignore trailing '/' when comparing pathnames, so that
"tar -u" works again.  Otherwise, "tar -u" wants to
treat every dir as new and re-adds it.
2007-04-18 04:36:11 +00:00
Tim Kientzle
007c50304b When testing basic functionality, strip trailing '/' from
dir names, so they match the names generated by 'find'.
2007-04-18 04:35:17 +00:00