Commit Graph

12 Commits

Author SHA1 Message Date
Bruce Evans bd4f43ff72 mount(8) only uses realpath() for the mountpoint, so don't look up the
real path here for the mount device (or path).  This fixes difficulties
unmounting devices that are actually symlinks to real devices.

Also, print the original path instead of the real path in early error
messages.  nfs path handling and later error messages may still be wrong,
probably only in silly cases where the original path is both a symlink
and a remote path.

PR:		5208
1998-01-19 18:48:36 +00:00
Warner Losh b1a3bc5ea0 style(9) corrections
Submitted by:	bde
1997-12-26 23:28:17 +00:00
Warner Losh 5635438650 Be extra paranoid about trusting the length of the data returned by
gethostbyaddr.
Submitted by:	Julian Assange
1997-12-24 01:00:24 +00:00
Philippe Charnier 210a5dc89f Sync usage string according to man page. 1997-06-19 14:44:24 +00:00
Bruce Evans d499a0ef65 Merge from Lite2.
- use new getvfsbyname() interface.
- new -A option, like -a except only mounted file systems are unmounted.

All non-cosmetic FreeBSD changes in umount.c, except ignoring of
realpath() failures, went away because they are done better in Lite2.
realpath() failures must be ignored so that non-pathnames like
"<above>:/foo" and "host:/bar" get as far as mount(2).

Reviewed by:	dfr
1997-06-16 11:20:05 +00:00
Doug Rabson 43f67e2b2e Generalise the previous change so that only NFS hostnames are looked up.
PR:		bin/3588
Suggested by:	Joerg Wunsch <joerg_wunsch@uriah.heep.sax.de>
1997-05-16 10:27:02 +00:00
Doug Rabson a0bc68a48e Don't try to look up unionfs' <above>, <below> keywords as hostnames. 1997-04-29 09:10:11 +00:00
Warner Losh 8d64695c7c compare return value from getopt against -1 rather than EOF, per the final
posix standard on the topic.
1997-03-29 03:33:12 +00:00
Rodney W. Grimes 5ebc7e6281 Remove trailing whitespace. 1995-05-30 06:12:45 +00:00
Garrett Wollman a5ce0490a4 Fix initialization error that caused `mount -vat' to behave unexpectedly
in certain circumstances.  Fixes PR #182.

Submitted by:	Andrew Atrens <atreand@statcan.ca>
1995-04-10 18:57:08 +00:00
David Greenman 5974081cea From njw@cs.city.ac.uk (Nick Williams):
/sbin/umount does not return the correct exit status due to incorrect
logic in its internals.

Further, because of the nature of the code, you *cannot* use it to
umount a directory from a union mountpoint. Well, you can sometimes,
it depends on if the directory is at the top of the union stack or not :)

Submitted by:	njw@cs.city.ac.uk (Nick Williams)
1994-11-04 17:51:37 +00:00
Rodney W. Grimes 8fae3551ec BSD 4.4 Lite sbin Sources
Note:  XNSrouted and routed NOT imported here, they shall be imported with
usr.sbin.
1994-05-26 06:35:07 +00:00