Fixes "getty: unrecognized option '--loginpause'"

Usage incorrectly stated --loginpause is a valid option, where instead --login-pause is.

Also --no-hostname --> --nohostname.
lsblk: use devno to get mountpoint

The device (for example LVM logical volume) could be renamed and then
the device name from /proc/self/mountinfo does not match with reality.
So, we also need to check devno. Unfortunately we cannot completely
rely on devno, because for example btrfs uses psudo device numbers.

References: https://bugzilla.redhat.com/show_bug.cgi?id=980463
Signed-off-by: Karel Zak <kzak@redhat.com>
lsblk: use devno to check if the filesystem is mounted

The device (for example LVM logical volume) could be renamed and then
the device name from /proc/self/mountinfo does not match with reality.
So, we also need to check devno. Unfortunately we cannot completely
rely on devno, because for example btrfs uses psudo device numbers.

References: https://bugzilla.redhat.com/show_bug.cgi?id=980463
Signed-off-by: Karel Zak <kzak@redhat.com>
include/xalloc: add warn_unused_result to allocation functions

Signed-off-by: Karel Zak <kzak@redhat.com>
unshare: add --fork options for pid namespaces

The ability of unshare to launch a new pid namespace is a bit limited.
The first process in the namespace is expected to be the "init" for it.
When it's not, you get bad behavior.

For example, trying to launch a shell in a new pid namespace fails very
quickly:
	$ sudo unshare -p dash
	# uname -r
	3.8.3
	# uname -m
	dash: 2: Cannot fork
	# ls -ld /
	dash: 3: Cannot fork
	# echo $$
	1324

For this to work smoothly, we need an init process to actively watch over
things.  But forcing people to re-use an existing init or write their own
mini init is a bit overkill.  So let's add a --fork option to unshare to
do this common bit of book keeping.  Now we can do:
	$ sudo unshare -p --fork dash
	# uname -r
	3.8.3
	# uname -m
	x86_64
	# ls -ld /
	drwxr-xr-x 22 root root 4096 May  4 14:01 /
	# echo $$
	1

Thanks to Michael Kerrisk for his namespace articles on lwn.net

[kzak@redhat.com: - fix "forkif logic, remove --mount-proc]

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
unshare: add --mount-proc for pid namespaces

Based on patch from Mike Frysinger <vapier@gentoo.org>.

Mike Frysinger wrote:
 When it comes to pid namespaces, it's also useful for /proc to reflect
 the current namespace.  Again, this is easy to pull off, but annoying
 to force everyone to do it themselves.  So let's add a --mount-proc to
 do the magic for us.  The downside is that this also implies creating
 a mount namespace as mounting the new pid namespace /proc over top the
 system one will quickly break all other processes on the system.

Signed-off-by: Karel Zak <kzak@redhat.com>
Acked-by: Mike Frysinger <vapier@gentoo.or>
docs: improve formatting and wording of man pages for fdisk and cfdisk

Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
docs: fix wording and formatting of man page for dmesg

Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
docs: make description of --activate clearer on man page of sfdisk

Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
Merge branch 'patch-1' of https://github.com/kernc/util-linux

* 'patch-1' of https://github.com/kernc/util-linux:
  Fixes "getty: unrecognized option '--loginpause'"
sfdisk: make unhiding as complete as possible

It is unlikely anyone will ever need this, but I like idea commands being
complete.  The partition id's that can be unhide after this change are;

Hidden HPFS/NTFS
Hidden W95 FAT32
Hidden W95 FAT32 (LBA)
Hidden W95 FAT16 (LBA)

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
docs: add missing options to sfdisk manual

And improve what is said about four of the dangerous options.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
dmesg: inform user --show-delta and iso8601 time format does not mix

References: http://marc.info/?l=util-linux-ng&m=137267606929951&w=2
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
lib/loopdev: assigned value is never read [clang-analyzer]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
lib/mbsalign: initializations values are never read [clang-analyzer]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
ipcs: assigned values are never read [clang-analyzer]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
lscpu: fix memory leak [clang-analyzer]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
more: assigned value is never read [clang-analyzer]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
utmpdump: assigned values are never read [clang-analyzer]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
mkfs.cramfs: argument to free() is a constant address [clang-analyzer]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>