Commit graph

6464 commits

Author SHA1 Message Date
Karel Zak
b75b23b42f docs: cleanup TODO
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-18 17:07:39 +01:00
Karel Zak
aa192520d3 dmesg: use $PAGER for --human output, add --nopager
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-18 14:05:24 +01:00
Karel Zak
f0a3a1caac dmesg: add --human
* enable --reltime
 * enable --color
 * a little bit cleanup main()

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-18 12:38:28 +01:00
Karel Zak
5aaee63cdf dmesg: more colors, more fun
* colorize subsystem prefix
 * colorize time
 * colorize by keywords (now "segfault" only)

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-18 12:28:32 +01:00
Joseph Parmelee
d53f8ecfbf hwclock: make hwclock leap-second-aware
Attached is a patch file leap_seconds.patch against util-linux-2.22.2
that allows leap seconds to be included in hwclock --show or --hctosys.
The current code uses the default UTC zonefile in reading the hardware
RTC with mktime().  This zonefile usually does not include leap
seconds.  As of this date there have been a total of 25 leap seconds
added since the epoch (start of 1970).  This is particularly a problem
for systems using ntp to maintain their system clocks because ntp does
take leap seconds into account.  A user can specify a leap-second-aware
zonefile via /etc/localtime.  By defining the environment variable
TZUTC, mktime() can be induced to use a matching UTC zonefile that
includes leap seconds.  The default behavior (TZUTC undefined) is
unchanged.

Regards,

Joseph Parmelee
jparmele at wildbear.com
2013-03-18 10:31:32 +01:00
Karel Zak
52848780e3 fsck.cramfs: fix compiler warnings
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-15 15:33:23 +01:00
Karel Zak
2029dbd9b1 docs: update year
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-15 15:18:22 +01:00
Karel Zak
a3bb7e65c4 libmount: clean up header file
* don't teach people C by header files, so use warn_unused_result
   attribute only on places where we return allocated memory (to avoid
   leaks in applications).

 * merge multiple function attributes to the one list to make it
   usable with gtk-doc

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-15 14:59:22 +01:00
Karel Zak
2bb7a706a1 libblkid: clean up header file
* don't teach people C by header files, so use warn_unused_result
   attribute only on places where we return allocated memory (to avoid
   leaks in applications).

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-15 14:59:02 +01:00
Karel Zak
bc636434c0 build-sys: inform gtk-doc about __ul_attribute__
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-15 14:58:08 +01:00
Karel Zak
c0055e2ac0 libblkid: fix docs comment
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-15 12:47:53 +01:00
Karel Zak
58a3cee647 chkdupexe: remove, deprecated for years
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-14 13:34:11 +01:00
Karel Zak
27abd80948 arch: remove the command, deprecated since 2.13, use coreutils version
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-14 12:22:11 +01:00
Karel Zak
426f0ceac7 findmnt: add FREQ and PASSNO columns
... to provide all information from fstab.

Reported-by: Roger Leigh <rleigh@codelibre.net>
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-14 10:50:37 +01:00
Karel Zak
f546276e22 kill: support --list=<signal>
The '=' is expected for optional arguments and required in procps version.

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 16:02:55 +01:00
Sami Kerola
fda84b66ee kill: add pretty printed list output (for compatibility with procps)
* add -L, --table

References: http://www.freelists.org/post/procps/kill1-consolidation
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 15:47:12 +01:00
Josh Triplett
b00456d2f0 namespace.h: Fix typo: s/CLONE_NEWSNS/CLONE_NEWNS/
This typo causes namespace.h to always unconditionally define
CLONE_NEWNS rather than using the system definition.

Bug present since the initial version of unshare in commit
4205f1fda1.

Signed-off-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Anton Cherkashyn <mail@antonc.com>
2013-03-13 14:47:25 +01:00
Karel Zak
77fa36d7c6 include/timer: return setitimer return value
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 14:07:23 +01:00
Karel Zak
d4543f843d fsfreeze: check for collision between options
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 13:07:32 +01:00
Karel Zak
2c7bcdf868 include/optutils: make collisions detection between options more robust
- don't rely on the correct ul_excl_t usage
 - don't print --(null) for non-existing long options

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 13:04:02 +01:00
Karel Zak
7de20424b7 fsfreeze: clean up usage(), add -V
- clean up usage()
 - add -V,--version
 - print usage() if not action specified
 - update man page

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 12:32:30 +01:00
Karel Zak
907624ebb0 flock: use include/timer.h
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 12:13:55 +01:00
Karel Zak
01acff6e09 include: add timer.h
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 12:13:11 +01:00
Karel Zak
880c4045e5 flock: use strtotimeval() from libcommon
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 11:52:34 +01:00
Karel Zak
477254da93 lib/strutils: add strtotimeval_or_err()
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-13 11:51:15 +01:00
Karel Zak
f1e7f7d54e kill: use new API from lib/procutils.c
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 17:40:31 +01:00
Karel Zak
13377dd64a lib/procutils: add simple API to scan /proc/PID/*
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 17:24:14 +01:00
Karel Zak
ef5b971c78 tests: move fallocate test file
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 16:08:23 +01:00
Karel Zak
a558cff0ca tests: move tailf test input
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 15:56:49 +01:00
Karel Zak
1bb53a5435 lib/procutils: test refactoring
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 15:45:59 +01:00
Sami Kerola
9e068ce0f1 docs: add long options and tidy up kill.1
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-03-12 15:24:33 +01:00
Sami Kerola
ea72260cbe kill, procs: use pid_t for pids
Reference: http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/include/linux/threads.h#n30
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 15:24:04 +01:00
Sami Kerola
44e5fcddc0 kill: use libc error printing facilities and exit values
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 14:42:21 +01:00
Sami Kerola
a5618319e6 kill: align with howto-usage-function.txt
[kzak@redhad.com: - s/commandname/name/
                  - improve --all description
                  - add -h/--help]

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 14:41:13 +01:00
Sami Kerola
daa54393bc kill: add long options
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-03-12 14:31:42 +01:00
Karel Zak
9ed268d0a7 fdisk: improve MBR detection
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 11:58:34 +01:00
Karel Zak
d23c661c47 fdisk: no more AIX "support"
The whole AIX support in fdisk has been limited to pretty poor AIX
magic string detection and warning that the AIX is unsupported. It's
too expensive to maintain such fdisk driver.

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 11:37:33 +01:00
Karel Zak
c71bf40751 tests: update fdisk tests
- the new fdisk ask-partition-number dialog does not ask for non-senses
   (non-existing partitions etc.)

 - 'p'rint command prints disk label name (usually "dos" in the tests)

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 11:27:28 +01:00
Karel Zak
38de0706e8 fdisk: use comma in the ask-partition-number dialog (again)
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-12 10:58:33 +01:00
Karel Zak
2b0eda8ee9 tests: update aks-partition-number dialog (planned regression)
Since 2.23 the fdisk ask-partition-number dialog don't ask for
partition number if there is only one partition. This was default in
DOS driver, now it's default everywhere.

For Sun/BSD it's regression... but we don't want to maintain any extra
code --- sorry --- we don't want any exception in the code.

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 16:15:36 +01:00
Karel Zak
23ce9df745 tests: update 'odd input' fdisk test
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 16:05:29 +01:00
Karel Zak
b4fb2a6110 fdisk: (bsd) support non-nested version too
note that btrydev() should be unnecessary, regular list_table()
should be enough for all types.

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 15:56:05 +01:00
Karel Zak
1aefdc35db tests: fix typo in fdisk test
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 15:40:20 +01:00
Karel Zak
a35e816ea9 tests: update bsd test
This is the correct 'L'ist partition types dialog output for BSD.

Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 15:15:32 +01:00
Karel Zak
32011e8925 tests: ignore stderr in fdisk -l
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 15:14:51 +01:00
Karel Zak
82d55456a9 fdisk: remove comma from ask number dialog
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 13:00:58 +01:00
Karel Zak
641a75ca99 fdisk: use fdisk_ask_partnum() everywhere
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 13:00:58 +01:00
Karel Zak
e09435aa53 fdisk: (bds) use nested partition table
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 13:00:58 +01:00
Karel Zak
01b207133e libfdisk: add support for nested contexts
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 13:00:57 +01:00
Karel Zak
5c72641a5e libblkid: ignore nested BSD partitions if same like parent
Signed-off-by: Karel Zak <kzak@redhat.com>
2013-03-11 13:00:57 +01:00