Commit Graph

366 Commits

Author SHA1 Message Date
steve
14b3c0a4f8 Fix redirection of unopened file descriptors and nuke register
keyword usage.

Obtained from: NetBSD
1997-04-28 03:25:13 +00:00
steve
e310a7dada Revert changes from rev 1.16 to 1.17 for now. Closes PR 2879. 1997-04-28 03:22:09 +00:00
steve
608d3e61dc mdoc-ify and cleanup UNIMPLEMENTED messages. Closes PR 2880. 1997-04-28 03:20:09 +00:00
steve
4d58ce1f53 Reorder declarations slightly. 1997-04-28 03:17:51 +00:00
steve
2d8d8d0891 Avoid a possible NULL pointer dereference, nuke register usage,
and remove an unnecessary reset.

Obtained from: NetBSD
1997-04-28 03:16:12 +00:00
steve
1d8c8cc1cb Nuke register keyword usage, #if -> #ifdef, and avoid void *
arithmetic.

Obtained from: NetBSD
1997-04-28 03:14:04 +00:00
steve
f7ea4486cb Nuke register keyword usage, rename pread to preadfd, and open
input files FD_CLOEXEC.

Obtained from: NetBSD
1997-04-28 03:11:52 +00:00
steve
a6b0a4171a When NO_HISTORY is defined and the history command is used
show an error message.

Inspired by: NetBSD
1997-04-28 03:10:31 +00:00
steve
d629ba9f89 Add a type builtin and nuke register keyword usage.
Obtained from: NetBSD
1997-04-28 03:08:38 +00:00
steve
6869cb59bf Nuke register keyword usage and #if -> #ifdef.
Obtained from: NetBSD
1997-04-28 03:06:52 +00:00
steve
313e34c452 Shamelessly pilfer most of NetBSD's Makefile so that the
problem with 'make -j n' and no .depend file goes away.
I think Bruce mentioned this somewhere on one of the
mailing lists.

Obtained from: NetBSD
1997-04-28 03:03:23 +00:00
jdp
ce525b762d When "-c" is specified, don't pad the command with spaces if it is
the last field on the line.  "ps -axlc" was needlessly wrapping
around on 80-character windows.
1997-04-16 16:08:11 +00:00
danny
c95d878851 Fix typo in comment; Document in an example that years beyond 1999
are handled; fix typo in same example.
1997-04-16 05:59:21 +00:00
mpp
969cc91da0 Provide examples of how to remove file names that begin with
a dash in non-getopt implementations.  E.g.:
	rm /home/mpp/-filename
	rm ./-filename

Requested by: bde
1997-04-09 05:04:43 +00:00
mpp
9baabea624 Improve the wording in the NOTES section. Closes PR# 3223. 1997-04-08 20:27:48 +00:00
mpp
b886336680 Fix several problems with mkdir:
1)  Fix mkdir -p to exit with the proper exit status and issue an error
    message if it was unable to create all of the specified directories
    and they did not previously exist.  POSIX says:

    The mkdir utility shall exit with one of the following values:

    0  All the specified directories were created successfully or the
       -p option was specified and all the specified directories now
       exist.

    E.g.

    % mkdir -p /var/mkdir
    mkdir: /var/mkdir: Permission denied

    % touch /tmp/file
    % mkdir -p /tmp/file/dir
    mkdir: /tmp/file: Not a directory

    Previously the above examples would exit with a zero exit status
    and no error message.  Something like the following run as a
    normal user will still not produce an error:

    % id
    uid=629(mpp) gid=629(mpp)....
    % mkdir -p /usr/local/etc
    % ls -ld /usr/local/etc
    drwxr-xr-x  4 bin  bin  512 Dec 26 14:55 /usr/local/etc/

2)  Cleaned up the mode handling to be more efficient when multiple
    directories are being created.

3) Fixed a problem where directories could be created with the wrong mode
   if the the -p option was specified and the build() routine returned
   and error.  It would leave the umask set incorrectly at this point.

4) Removed an unused variable.

Closes PR# 2304.
1997-04-01 23:46:22 +00:00
imp
cd84ece5fd compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.
1997-03-29 04:34:07 +00:00
imp
cdc0e920d8 compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.
1997-03-28 15:24:41 +00:00
obrien
a09ae5e9bd make usage() and SYNOPSIS agree with each other and add missing options
documented in the DESCRIPTION section.
1997-03-26 17:48:40 +00:00
imp
ad42e7a13f Use mkstemp rather than mktemp to prevent races.
Obtained from: OpenBSD
1997-03-24 05:45:29 +00:00
bde
1d35a01a65 Merged from Lite2. The -t option is now handled better. The only visible
change should be that the usage message now actually matches the man page.
1997-03-13 17:41:37 +00:00
bde
909dc1b5d2 Merged from Lite2. The man page no longer attempts to list all the
vfs types.

Fixed ordering of FreeBSD `k' option in synopsis.
1997-03-13 17:32:39 +00:00
bde
52b723e9b1 Merge from Lite2. Straightforward changes. 1997-03-13 17:29:08 +00:00
mpp
1b659768bd Correct the self reference in the description of the "tabs" option.
It should really refer to "oxtabs".

Obtained from: NetBSD-bugs mailing list PR# 3320
1997-03-12 15:59:22 +00:00
guido
6424c35fe5 Fix buffer overflow 1997-03-10 19:52:12 +00:00
guido
301e38a7c7 This is a funny one: df for a device that was not mounted used to fail
for root only.
1997-03-10 19:39:43 +00:00
guido
ee328d1053 Fix buffer overflow (probably unexploitable). 1997-03-10 19:10:08 +00:00
guido
b8d3beac13 Make mv more robust. A race has been fixed, as well as an extra warning
added when sbits are cleared.
Fixes PR 1351 and 1377 (I hope).
1997-03-08 16:05:44 +00:00
mpp
d8a1c85007 Typo fix. 1997-03-07 01:58:56 +00:00
joerg
fbe645d9f1 Acitvate chio(1). 1997-03-06 15:30:53 +00:00
joerg
f80cb70ae2 This commit was generated by cvs2svn to compensate for changes in r23449,
which included commits to RCS files with non-trunk default branches.
1997-03-06 15:30:06 +00:00
joerg
22817fb6a1 Import Jason Thorpe's contribution for an updated SCSI media changer
device (now, finally!).
1997-03-06 15:30:06 +00:00
ache
ef8eca45e6 Big usernames fixes 1997-03-04 00:33:56 +00:00
ache
d653dc5901 Use MAXLOGNAME-1 for width because MAXLOGNAME includes NUL 1997-03-03 08:20:28 +00:00
mpp
5eda08fa42 Add a missing period in the -o option description.
Document the depreciated -g option.

Inspired by: OpenBSD PR# 119
1997-02-25 00:26:53 +00:00
peter
34fd560164 Revert $FreeBSD$ to $Id$ 1997-02-22 14:13:04 +00:00
mpp
297ecb20eb Use the .Bx macro in the HISTORY section. 1997-02-19 07:14:30 +00:00
obrien
9f6eb5fe55 Add history section. Follows chflags(2). 1997-02-19 00:32:35 +00:00
jkh
3626596097 Include <ufs/ufs/ufsmount.h>. 1997-02-17 05:26:08 +00:00
steve
d9abae43ae Fix a expansion bug that caused the result of echo $((1 << 30))
to get truncated.

Submitted by: bde
1997-02-16 01:54:19 +00:00
alex
ee019a53dc Sweep through the tree fixing mmap() usage:
- Use MAP_FAILED instead of the constant -1 to indicate
    failure (required by POSIX).
  - Removed flag arguments of '0' (required by POSIX).
  - Fixed code which expected an error return of 0.
  - Fixed code which thought any address with the high bit set
    was an error.
  - Check for failure where no checks were present.

Discussed with:	bde
1997-01-16 21:58:40 +00:00
jkh
9c0cd3f9df Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore.  This update would have been
insane otherwise.
1997-01-14 07:20:47 +00:00
wosch
e902881dbf Sort cross references. 1997-01-13 00:25:51 +00:00
mpp
0ed99fc645 Minor mdoc cleanup. 1997-01-11 19:47:07 +00:00
mpp
4112c40287 Add a blurb describing the fact that ls will print the
year in place of the hour/minute fields if the time is
more than 6 months in the past or future.

Also some minor mdoc cleanup.
1997-01-11 19:24:22 +00:00
mpp
ae122c8fd8 Make ls include the year when displaying times that are more than
6 months into the future.  Closes PR# 1657.

Submitted by:	Sakari Jalowaara <sja.home.tekla.fi>
1997-01-11 19:15:53 +00:00
steve
d8f6e783a9 Fix a problem that caused some foreground pipelines to die with:
tcsetpgrp failed, errno=1

Discovered and Reviewed by: joerg
1997-01-06 01:26:44 +00:00
steve
52b42d179f Make sh(1) think and be in the same place at the same time. This closes
PR#2331: strange output of sh's pwd on symlinked directories.
1997-01-04 19:14:29 +00:00
wosch
7d81d73be3 add some string examples, eg. test "" -o "" 1996-12-28 13:31:29 +00:00
ache
2b16798128 Use strcoll instead of strcmp for file names comparation
Should be in 2.2
1996-12-28 03:46:27 +00:00