]>
git.ipfire.org Git - thirdparty/util-linux.git/log
Karel Zak [Fri, 20 Jul 2012 10:09:09 +0000 (12:09 +0200)]
dmesg: read /dev/kmsg (since kernel 3.5.0)
kmsg advantages:
- extendible format
- tags for messages
- one read() returns one complete record
See kernel Documentation/ABI/testing/dev-kmsg.
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 19 Jul 2012 16:35:20 +0000 (18:35 +0200)]
dmesg: add --syslog to force to old syslog(2) interface
... just for debugging or for people who somehow depends on syslog(2)
behavior.
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 19 Jul 2012 16:33:20 +0000 (18:33 +0200)]
dmesg: refactoring for kmsg support
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 19 Jul 2012 15:12:54 +0000 (17:12 +0200)]
dmesg: unify internal APIs
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 19 Jul 2012 15:01:05 +0000 (17:01 +0200)]
dmesg: cleanup, move more stuff to control struct
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 19 Jul 2012 14:33:08 +0000 (16:33 +0200)]
dmesg: move filename to control struct
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Wed, 18 Jul 2012 20:09:24 +0000 (22:09 +0200)]
libmount: check VFS mount options in mnt_diff_tables()
after "-o remount,ro" in unshared namespace is the original VFS entry
still read-write:
original:
42 21 8:2 / /boot rw,relatime - ext4 /dev/sda2 ro,user_xattr,acl,barrier=1,data=ordered
unshared + ro remount:
78 51 8:2 / /boot ro,relatime - ext4 /dev/sda2 ro,user_xattr,acl,barrier=1,data=ordered
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Tue, 17 Jul 2012 20:08:27 +0000 (22:08 +0200)]
docs: update TODO
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Tue, 17 Jul 2012 20:02:35 +0000 (22:02 +0200)]
mount: (new) add --source and --target
In some cases (for example if only one mount argument is given) may be
mount request ambivalent:
# mount /foo
and fstab:
/dev/sda5 /foo rw 0 0
/foo /bar bind 0 0
the new options allows to be more explicit
# mount --target /foo (mounts /dev/sda5)
# mount --source /foo (binds /foo to /bar)
It's possible to use the options together
# mount --source /dev/sda2 --target /home
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Tue, 17 Jul 2012 19:57:22 +0000 (21:57 +0200)]
libmount: allow to disable swap between source and target
In some cases (for example if only one mount argument is given) may be
mount request ambivalent:
# mount /foo
and fstab:
/dev/sda5 /foo rw 0 0
/foo /bar bind 0 0
The libmount allows to swap between source and target (if
source is not LABEL or UUID) by default. The new function
mnt_context_disable_swapmatch()
allows to disable this feature.
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Tue, 17 Jul 2012 13:22:51 +0000 (15:22 +0200)]
docs: update TODO file
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:57:30 +0000 (18:57 +0200)]
mkfs.cramfs: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:55:39 +0000 (18:55 +0200)]
eject: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:55:01 +0000 (18:55 +0200)]
fsck.cramfs: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:53:11 +0000 (18:53 +0200)]
ldattach: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:52:30 +0000 (18:52 +0200)]
lscpu: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:51:27 +0000 (18:51 +0200)]
setarch: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:50:39 +0000 (18:50 +0200)]
cytune: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:49:36 +0000 (18:49 +0200)]
ipcmk: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:48:27 +0000 (18:48 +0200)]
scriptreplay: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:47:29 +0000 (18:47 +0200)]
tailf: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:46:44 +0000 (18:46 +0200)]
colrm: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:45:52 +0000 (18:45 +0200)]
raw: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:43:53 +0000 (18:43 +0200)]
hwclock: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:38:14 +0000 (18:38 +0200)]
test_sysinfo: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:36:27 +0000 (18:36 +0200)]
kill: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:31:45 +0000 (18:31 +0200)]
su: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:29:22 +0000 (18:29 +0200)]
lib/match: fix compiler warning [-Wmissing-prototypes]
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 16:19:08 +0000 (18:19 +0200)]
Merge branch '2012wk28'
* 2012wk28:
translation: unify file open error messages
translation: unify stat error messages
utmpdump: use help and version output macros
su: align with howto-usage-function
fdisk: make if clause easier to read
look: remove extra semicolon
utmpdump: remove unused variable
swapon: remove unused variables
lib/loopdev: minor bug fix: add missing semicolon
lib/pager: minor compiler warning fixes
libblkid: remove duplicate entries in symbols
Sami Kerola [Sun, 15 Jul 2012 08:39:57 +0000 (10:39 +0200)]
translation: unify file open error messages
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sun, 15 Jul 2012 08:17:53 +0000 (10:17 +0200)]
translation: unify stat error messages
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sun, 15 Jul 2012 07:57:31 +0000 (09:57 +0200)]
utmpdump: use help and version output macros
Done to reduce translation project work.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sun, 15 Jul 2012 07:46:45 +0000 (09:46 +0200)]
su: align with howto-usage-function
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sun, 15 Jul 2012 06:58:51 +0000 (08:58 +0200)]
fdisk: make if clause easier to read
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sat, 14 Jul 2012 21:50:15 +0000 (23:50 +0200)]
look: remove extra semicolon
The both macro SKIP_PAST_NEWLINE and location where macro is used will
not need semicolon at the end of line.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sat, 14 Jul 2012 21:47:07 +0000 (23:47 +0200)]
utmpdump: remove unused variable
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sat, 14 Jul 2012 21:44:56 +0000 (23:44 +0200)]
swapon: remove unused variables
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sat, 14 Jul 2012 21:35:41 +0000 (23:35 +0200)]
lib/loopdev: minor bug fix: add missing semicolon
Missing semicolon made test_loop_info() to return function
loopcxt_enable_debug() return value, which happen to be void. I
suspect the loopcxt_enable_debug() was usually not executed, while it
should be.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sat, 14 Jul 2012 21:16:28 +0000 (23:16 +0200)]
lib/pager: minor compiler warning fixes
Add missing function prototype, and declare structure before use of it.
lib/pager.c:162:6: warning: no previous prototype for function 'setup_pager' [-Wmissing-prototypes]
lib/pager.c:20:29: warning: tentative definition of variable with internal linkage has incomplete non-array type 'struct child_process' [-Wtentative-definition-incomplete-type]
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sat, 14 Jul 2012 20:25:25 +0000 (22:25 +0200)]
libblkid: remove duplicate entries in symbols
The commit
a0487b1cb5beffb8f6783476664b01e8833e0ea8 added symbol
dublicates. The symbols should only be listed in BLKID_1.0 segment.
/usr/bin/ld.gold: warning: using 'BLKID_1.0' as version for 'blkid_probe_all' which is also named in version 'BLKID_2.15' in script
/usr/bin/ld.gold: warning: using 'BLKID_1.0' as version for 'blkid_probe_all_new' which is also named in version 'BLKID_2.15' in script
copying selected object files to avoid basename conflicts...
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Petr Uzel [Thu, 12 Jul 2012 09:47:19 +0000 (11:47 +0200)]
fdisk: rename label probing functions
Rename check_$foo_label() to $foo_probe_label():
1/ 'probe' is more appropriate verb than 'check' for these functions
2/ making label name first part of the funciton name is IMO more
friendly for tags completion (e.g. vim + cscope/ctags).
Signed-off-by: Petr Uzel <petr.uzel@suse.cz>
Petr Uzel [Thu, 12 Jul 2012 09:47:18 +0000 (11:47 +0200)]
fdisk: don't call update_units() in label probes if not necessary
update_units() is called in _probe_labels before the label probes are
started, so we don't need to call it again in probers, unless it messes
around with geometry, which currently only check_sun_label() does (so
keep the call to update_units() in this one).
Signed-off-by: Petr Uzel <petr.uzel@suse.cz>
Petr Uzel [Thu, 12 Jul 2012 09:18:46 +0000 (11:18 +0200)]
utmpdump: kill unused variable in follow_by_inotify()
Signed-off-by: Petr Uzel <petr.uzel@suse.cz>
Petr Uzel [Thu, 12 Jul 2012 08:09:59 +0000 (10:09 +0200)]
libblkid: cast blkid_loff_t to unsigned long long
Get rid of gcc warning and fix build with -Werror
Signed-off-by: Petr Uzel <petr.uzel@suse.cz>
Petr Uzel [Thu, 12 Jul 2012 08:09:58 +0000 (10:09 +0200)]
swapon: kill unused variables in show_table()
Signed-off-by: Petr Uzel <petr.uzel@suse.cz>
Ville Skyttä [Wed, 11 Jul 2012 20:16:15 +0000 (23:16 +0300)]
docs: man page syntax fixes
Signed-off-by: Ville Skyttä <ville.skytta@iki.fi>
Eryu Guan [Wed, 11 Jul 2012 12:49:54 +0000 (20:49 +0800)]
mount: ext4 option inode_readahead should be inode_readahead_blks in mount.8
Mount option inode_readahead should be inode_readahead_blks. Also the
value should be a power of 2.
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
Davidlohr Bueso [Sun, 8 Jul 2012 21:40:27 +0000 (23:40 +0200)]
fdisk: API: add label probing functionality
This patch sets the initial layout for label specific operations. A
new fdisk_label structure is created that will hold all these ops,
like new, delete, write and probe, among others. For now only probing
is implemented. Once this design is established, a copy of the probed
label will be copied to the main context structure, where calling the
specific functions will save 'disklabel' checks. Debugging support is
added as well.
This patch passes regression tests and manually passes bsd, sun, dos
and sgi labels probes.
Reviewed-by: Petr Uzel <petr.uzel@suse.cz>
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
Karel Zak [Mon, 16 Jul 2012 15:42:09 +0000 (17:42 +0200)]
build-sys: add -Werror to UL_WARN_ADD test
... so revert previous patches with extra options for clang.
Sometimes is simple solution so obvious that it's invisible :-)
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 15:16:15 +0000 (17:16 +0200)]
build-sys: exclude some CC warnings for clang
Reported-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 15:14:04 +0000 (17:14 +0200)]
build-sys: add exclude list to UL_ADD_WARN
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 16 Jul 2012 13:48:43 +0000 (15:48 +0200)]
build-sys: add UL_PROG_CLANG function, rename warnings.m4 -> compiler.m4
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 12 Jul 2012 15:43:34 +0000 (17:43 +0200)]
libmount: rename mnt_context_fstab_applied to mnt_context_tab_applied
The function is also usable in umount to detect is mtab has been
applied.
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 12 Jul 2012 14:33:52 +0000 (16:33 +0200)]
login: close tty before vhangup()
Let's close all tty file descriptors before vhangup() call.
References: https://lkml.org/lkml/2012/6/5/145
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 12 Jul 2012 14:31:22 +0000 (16:31 +0200)]
agetty: close tty before vhangup()
Let's close all tty file descriptors if called with --hangup option.
References: https://lkml.org/lkml/2012/6/5/145
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Wed, 11 Jul 2012 16:15:21 +0000 (18:15 +0200)]
agetty: make tcsetpgrp() optional
The session setup TIOCSCTTY is optional, so tcsetpgrp() that depends
on controlling terminal should be optional too.
Reported-by: Hilko Bengen <bengen@debian.org>
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Wed, 11 Jul 2012 16:00:09 +0000 (18:00 +0200)]
build-sys: add missing files
Reported-by: Bernhard Voelker <mail@bernhard-voelker.de>
Signed-off-by: Karel Zak <kzak@redhat.com>
Sami Kerola [Wed, 27 Jun 2012 21:24:56 +0000 (23:24 +0200)]
swapon: fix --summary output regression
Commit
64b588814e5f081a7ab37f820984aa7a2de9eee9 changed --summary
header alignment, and usage of spaces vs tabs in output.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Wed, 27 Jun 2012 20:51:34 +0000 (22:51 +0200)]
swapon: make --show size to be human readable by default
Cc: Bernhard Voelker <mail@bernhard-voelker.de>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
Sami Kerola [Sun, 24 Jun 2012 20:43:48 +0000 (22:43 +0200)]
swapon: add --show option
The --show uses lib/tt.c, which allows user to specify columns he is
interested of, and avoids using hard coded field sizes which may be
problematic when system has large enough swap.
[kzak@redhat.com: - improve usage(), remove unused code]
Cc: Bernhard Voelker <mail@bernhard-voelker.de>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
Sami Kerola [Sat, 23 Jun 2012 07:17:00 +0000 (09:17 +0200)]
uuidd: use configured run state directory in manual etc
[kzak@redhat.com: - minor clean up in configure.in]
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
Sami Kerola [Sat, 23 Jun 2012 07:02:36 +0000 (09:02 +0200)]
agetty: use configured run state directory
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sat, 23 Jun 2012 06:56:13 +0000 (08:56 +0200)]
uuidd: use run configured state directory
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
Sami Kerola [Sat, 23 Jun 2012 05:05:14 +0000 (07:05 +0200)]
build-sys: change --localstatedir to /run
Enable user to define where run state files are wrote. Default for
these files is /run. See reference for rationale why /var/run is no
longer the default.
Reference: http://lists.fedoraproject.org/pipermail/devel/2011-March/150031.html
CC: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Karel Zak [Tue, 10 Jul 2012 09:23:35 +0000 (11:23 +0200)]
utmpdump: cleanup file descriptor usage
- don't support --follow for stdin at all
- inotify based implementation closes the file, so don't close it in
main() again
Signed-off-by: Karel Zak <kzak@redhat.com>
Sami Kerola [Sun, 8 Jul 2012 21:20:04 +0000 (23:20 +0200)]
utmpdump: encourage users not to follow stdin
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Tue, 10 Jul 2012 08:59:58 +0000 (10:59 +0200)]
utmpdump: use inotify to when following file
Co-Author: Karel Zak <kzak@redhat.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Sun, 8 Jul 2012 19:03:14 +0000 (21:03 +0200)]
utmpdump: fixes based on static analysis [cppcheck]
[utmpdump.c:82]: (style) The function 'unspace' is never used
[utmpdump.c:131]: (style) The scope of the variable 't' can be reduced
[utmpdump.c:167]: (warning) scanf without field width limits can crash with huge input data
[kzak@redhat.com: - don't use scanf field width limits for integers]
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 9 Jul 2012 20:26:27 +0000 (22:26 +0200)]
fix buffer overrun in some calls to sscanf
Reported-by: Sergei Antonov <saproj@gmail.com>
Signed-off-by: Karel Zak <kzak@redhat.com>
Sami Kerola [Wed, 4 Jul 2012 20:33:15 +0000 (22:33 +0200)]
utmpdump: white space fix
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Sami Kerola [Tue, 3 Jul 2012 19:35:09 +0000 (21:35 +0200)]
docs: clean up utmpdump.1 manual
Align with Documentation/howto-man-page.txt
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Conflicts:
login-utils/utmpdump.1
Karel Zak [Mon, 9 Jul 2012 15:26:15 +0000 (17:26 +0200)]
libblkid: cleanup _attribute__ usage
Karel Zak [Mon, 9 Jul 2012 15:17:59 +0000 (17:17 +0200)]
Merge branch 'master' of https://github.com/dankamongmen/util-linux
Björn Jacke [Wed, 4 Jul 2012 20:00:08 +0000 (22:00 +0200)]
docs: mention the required mount options for journaled version 2 quota
Björn Jacke [Wed, 4 Jul 2012 12:49:43 +0000 (14:49 +0200)]
docs: add quota mount option support description for ext2
Bernhard Voelker [Tue, 3 Jul 2012 07:42:55 +0000 (09:42 +0200)]
utmpdump: document optional filename argument
Signed-off-by: Bernhard Voelker <mail@bernhard-voelker.de>
Bernhard Voelker [Thu, 28 Jun 2012 14:24:56 +0000 (16:24 +0200)]
findmnt: fix typo in manpage
Signed-off-by: Bernhard Voelker <mail@bernhard-voelker.de>
Dave Reisner [Sat, 30 Jun 2012 16:01:18 +0000 (12:01 -0400)]
build-sys: ensure BUILD_CFDISK is always defined
This avoids an error when configuring without ncurses:
configure: error: conditional "BUILD_CFDISK" was never defined.
Usually this means the macro was only invoked conditionally.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Karel Zak [Mon, 9 Jul 2012 15:03:19 +0000 (17:03 +0200)]
docs: remove unused config/texinfo.tex
Signed-off-by: Karel Zak <kzak@redhat.com>
Bernhard Voelker [Wed, 27 Jun 2012 13:23:05 +0000 (15:23 +0200)]
docs: fix typos found by misspellings
The tool misspellings (https://github.com/lyda/misspell-check)
detected several typos. Command used:
$ git ls-files | grep -v ^po/ | misspellings -f -
* Documentation/releases/v2.18-ReleaseNotes: Fix typo in news entry.
* NEWS: Likewise.
* config/texinfo.tex: Fix typo in comments.
* libmount/src/context.c: Fix typo in comment.
* libmount/src/fs.c: Likewise.
* login-utils/login.c: Likewise.
* login-utils.su.1: Fix typo in man page.
* sys-utils/chcpu.c: Fix typo in error message.
Signed-off-by: Bernhard Voelker <mail@bernhard-voelker.de>
Karel Zak [Mon, 9 Jul 2012 14:53:13 +0000 (16:53 +0200)]
build-sys: add -Wredundant-decls
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 9 Jul 2012 14:44:25 +0000 (16:44 +0200)]
build-sys: support separate libintl
Addresses: https://github.com/karelzak/util-linux/pull/13
Reported-by: Ben Walton <bwalton@artsci.utoronto.ca>
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Mon, 9 Jul 2012 14:23:51 +0000 (16:23 +0200)]
build-sys: always use default $(LDADD)
The global variable $(LDADD) is always used if program_LDADD is
not specified. Let's use $LDADD everywhere to avoid exceptions for
people who need to specify global $LDADD.
Signed-off-by: Karel Zak <kzak@redhat.com>
nick black [Sat, 7 Jul 2012 15:42:35 +0000 (11:42 -0400)]
use proper printf format spec %lu
nick black [Sat, 7 Jul 2012 15:42:17 +0000 (11:42 -0400)]
use memcpy() to cope with possible misalignment
nick black [Sat, 7 Jul 2012 15:41:15 +0000 (11:41 -0400)]
properly check for ansi c99 vsnprint truncation
nick black [Sat, 7 Jul 2012 15:40:45 +0000 (11:40 -0400)]
use GCC format __attribute__ on sprinf
Karel Zak [Wed, 4 Jul 2012 11:40:01 +0000 (13:40 +0200)]
hwclock: don't set time for --systz
Not sure why, but the current --systz uses non-NULL timeval for
settimeofday(). It means that build-in kernel warp clock mechanism is
not used and the system time is always modified.
The built-in kernel implementation allows to move the clock by
timezone only for very first settimeofday() call.
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 15:34:12 +0000 (17:34 +0200)]
utmpdump: use xalloc.h, minor coding style changes
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 15:27:40 +0000 (17:27 +0200)]
utmpdump: cleanup usage()
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 15:22:42 +0000 (17:22 +0200)]
utmpdump: add long options
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 15:09:51 +0000 (17:09 +0200)]
utmpdump: use err.h stuff
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 14:59:32 +0000 (16:59 +0200)]
utmpdump: add NLS and closestream support
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 14:56:04 +0000 (16:56 +0200)]
utmpdump: remove dead code
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 14:52:30 +0000 (16:52 +0200)]
utmpdump: remove libc5 support
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 14:43:37 +0000 (16:43 +0200)]
utmpdump: cleanup comments, funcs definition lines
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Fri, 29 Jun 2012 14:34:46 +0000 (16:34 +0200)]
utmpdump: new command, merge from sysvinit
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 28 Jun 2012 13:42:06 +0000 (15:42 +0200)]
findmnt: add TID column
just in case we read from more mountinfo files.
For example get mountpoint from the current namespace which is invisible
for initd (PID=1):
# unsahre -m bash
# mount /dev/sdb /mnt/test
# echo $$
30070
# findmnt -n -o TARGET,TID,SOURCE --task 1 --task $$ | \
sort -u --key=1,1 | awk ' ($2 != 1) { print $0 }'
/mnt/test 30070 /dev/sdb
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 28 Jun 2012 13:40:16 +0000 (15:40 +0200)]
libmount: save task ID for mountinfo tiles
Add new function mnt_fs_get_tid() to get task ID for the given filesystem.
Signed-off-by: Karel Zak <kzak@redhat.com>
Karel Zak [Thu, 28 Jun 2012 11:51:34 +0000 (13:51 +0200)]
findmnt: add --task <tid> option
Signed-off-by: Karel Zak <kzak@redhat.com>