partx: fix --update ranges and out of order tables

partx --update DEVICE NUMBER
was broken in 2 cases:
 * if NUMBER != 1
 * if the partition table was "out of order".
   Ie, where sda2 came after sda3.

References: https://bugs.launchpad.net/ubuntu/+source/cloud-utils/+bug/1244662
Signed-off-by: Scott Moser <smoser@ubuntu.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
tests: update partx sgi test

Since commit 4253275490926cf533bfd0bc33279729e9ff427a the libblkid
lists system partitions for SGI label.

Signed-off-by: Karel Zak <kzak@redhat.com>
tests: add partx --update test

Signed-off-by: Karel Zak <kzak@redhat.com>
docs: add lslogins(1) to TODO

Signed-off-by: Karel Zak <kzak@redhat.com>
lscpu: sort NUMA nodes to keep output human readable

Signed-off-by: Karel Zak <kzak@redhat.com>
tests: update lscpu tests

Signed-off-by: Karel Zak <kzak@redhat.com>
pylibmount: remove unncessary subdirectory

Signed-off-by: Karel Zak <kzak@redhat.com>
pylibmount: import directly from pylibmount in tests

This change does not have any impact to in a standard way installed
libmount impact. It's simplification for in-tree tests.

Signed-off-by: Karel Zak <kzak@redhat.com>
more: fix mem leak [coverity scan]

... the code is so soo ugly.

Signed-off-by: Karel Zak <kzak@redhat.com>
column: fix mem leak [coverity scan]

Signed-off-by: Karel Zak <kzak@redhat.com>
rename: fix mem leak [coverity scan]

Signed-off-by: Karel Zak <kzak@redhat.com>
libmount: fix scanf format string [coverity scan]

Signed-off-by: Karel Zak <kzak@redhat.com>
lib/sysfs: fix scanf format string [coverity scan]

Signed-off-by: Karel Zak <kzak@redhat.com>
libblkid: add blkid_partlist_get_partition_by_partno()

Signed-off-by: Karel Zak <kzak@redhat.com>
partx: use blkid_partlist_get_partition_by_partno()

Signed-off-by: Karel Zak <kzak@redhat.com>