-.\" $OpenBSD: pax.1,v 1.54 2008/06/11 07:42:50 jmc Exp $
+.\" $OpenBSD: pax.1,v 1.56 2009/02/08 17:33:01 jmc Exp $
.\" $NetBSD: pax.1,v 1.3 1995/03/21 09:07:37 cgd Exp $
.\"
.\" Copyright (c) 1992 Keith Muller.
.\"
.\" @(#)pax.1 8.4 (Berkeley) 4/18/94
.\"
-.Dd $Mdocdate: June 11 2008 $
+.Dd $Mdocdate: February 8 2009 $
.Dt PAX 1
.Os
.Sh NAME
The
.Nm
utility is compliant with the
-.St -p1003.1-2004
+.St -p1003.1-2008
specification.
.Pp
The flags
-.Op Fl 0BDEGHjLOPTUYZz ,
+.Op Fl 0BDEGjOPTUYZz ,
the archive formats
.Em bcpio ,
.Em sv4cpio ,
-.\" $OpenBSD: tar.1,v 1.50 2008/06/11 00:49:08 pvalchev Exp $
+.\" $OpenBSD: tar.1,v 1.51 2008/12/27 13:35:34 sobrado Exp $
.\"
.\" Copyright (c) 1996 SigmaSoft, Th. Lockert
.\" All rights reserved.
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.\"
-.\" $OpenBSD: tar.1,v 1.50 2008/06/11 00:49:08 pvalchev Exp $
+.\" $OpenBSD: tar.1,v 1.51 2008/12/27 13:35:34 sobrado Exp $
.\"
-.Dd $Mdocdate: June 11 2008 $
+.Dd $Mdocdate: December 27 2008 $
.Dt TAR 1
.Os
.Sh NAME
.Op Ar blocking-factor | archive | replstr
.Op Fl C Ar directory
.Op Fl I Ar file
-.Op Ar file ...
+.Op Ar
.Ek
.Nm tar
.No { Ns Fl crtux Ns }
+.Bk -words
.Op Fl 014578eHhjLmOoPpqvwXZz
.Op Fl b Ar blocking-factor
.Op Fl C Ar directory
.Op Fl f Ar archive
.Op Fl I Ar file
.Op Fl s Ar replstr
-.Op Ar file ...
+.Op Ar
+.Ek
.Sh DESCRIPTION
The
.Nm
-/* $OpenBSD: tty_subs.c,v 1.12 2003/06/02 23:32:09 millert Exp $ */
+/* $OpenBSD: tty_subs.c,v 1.13 2009/06/01 13:02:46 ray Exp $ */
/* $NetBSD: tty_subs.c,v 1.5 1995/03/21 09:07:52 cgd Exp $ */
/*-
#if 0
static const char sccsid[] = "@(#)tty_subs.c 8.2 (Berkeley) 4/18/94";
#else
-static const char rcsid[] = "$OpenBSD: tty_subs.c,v 1.12 2003/06/02 23:32:09 millert Exp $";
+static const char rcsid[] = "$OpenBSD: tty_subs.c,v 1.13 2009/06/01 13:02:46 ray Exp $";
#endif
#endif /* not lint */
int
tty_read(char *str, int len)
{
- char *pt;
-
- if ((--len <= 0) || (ttyinf == NULL) || (fgets(str,len,ttyinf) == NULL))
+ if (ttyinf == NULL || fgets(str, len, ttyinf) == NULL)
return(-1);
- *(str + len) = '\0';
/*
* strip off that trailing newline
*/
- if ((pt = strchr(str, '\n')) != NULL)
- *pt = '\0';
+ str[strcspn(str, "\n")] = '\0';
return(0);
}