summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* | wall: make sure ut_line is not emptyKarel Zak2019-06-061-4/+6
| | | | | | | | | | Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1711574 Signed-off-by: Karel Zak <kzak@redhat.com>
* | libblkid: fix detection of dm-integrity superblock versionMilan Broz2019-06-041-1/+1
|/ | | | | | | | Kernel 5.2 can use superblock version 3 for dm-integrity. Let's remove the explicit version check to be compatible with future extensions. Signed-off-by: Milan Broz <gmazyland@gmail.com>
* hardlink: fix bad formatting in hardlink.1Karel Zak2019-05-311-10/+10
| | | | | | | | * fix regex\f to regex\fR (issue #805) * replace \fP with \fR to be consistent with our another man pages Addresses: https://github.com/karelzak/util-linux/issues/805 Signed-off-by: Karel Zak <kzak@redhat.com>
* docs: add lscpu --caches to ReleaseNotesKarel Zak2019-05-311-1/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: release++ (v2.34-rc2)Karel Zak2019-05-302-3/+7
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* docs: update v2.34-ReleaseNotesKarel Zak2019-05-301-0/+133
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* docs: update AUTHORS fileKarel Zak2019-05-301-0/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* po: merge changesKarel Zak2019-05-3027-25729/+26617
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* po: update hr.po (from translationproject.org)Božidar Putanec2019-05-301-2941/+2715Star
|
* libmount: add selinuxfs between pseudo filesystemsKarel Zak2019-05-291-0/+1
| | | | | Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1714826 Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: add bpf between pseudo filesystemsKarel Zak2019-05-291-0/+1
| | | | | Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1714826 Signed-off-by: Karel Zak <kzak@redhat.com>
* findmnt: fix filters use on --listKarel Zak2019-05-291-1/+1
| | | | | Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1714826 Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: add asan build-sys testKarel Zak2019-05-291-0/+120
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* fdisk: add note about -S and -HKarel Zak2019-05-281-0/+4
| | | | | | | It's seems people still follow old advices for SSD/4K devices. Let's make CHS deprecation more visible at the begin of the man page... Signed-off-by: Karel Zak <kzak@redhat.com>
* ul: make sure buffers are zeroized [coverity scan]Karel Zak2019-05-281-2/+2
|
* column: make code more robust [coverity scan]Karel Zak2019-05-281-0/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* setpriv: fix memory leak in local scope [coverity scan]Karel Zak2019-05-281-1/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* setarch: avoid NULL dereference [coverity check]Karel Zak2019-05-281-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* rtcwake: terminate mode and excl[]Karel Zak2019-05-281-1/+5
| | | | | | | * terminate string read from /proc * terminate array for exclusive options Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: add info about ASANKarel Zak2019-05-281-0/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* renice: make code more readable for static analyzer [coverity scan]Karel Zak2019-05-281-1/+1
| | | | | | | It seems coverity and clag have no clue about relation between argv[] and argc. Let's make code more readable for them... Signed-off-by: Karel Zak <kzak@redhat.com>
* readprofile: be more explicit with used types [cppcheck]Karel Zak2019-05-281-2/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lscpu: check scols_line_set_data() return value [coverity scan]Karel Zak2019-05-281-1/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lscpu: make lookup() use more consistent [coverity scan]Karel Zak2019-05-281-2/+4
| | | | | | | We usually check lookup() return value. Let's do it in this case too. It seems static analyzers will be happy with consistent code. Signed-off-by: Karel Zak <kzak@redhat.com>
* mesg: avoid 'ttyname failed: Success' messageKarel Zak2019-05-273-5/+17
| | | | | | | | | | | | | The ttyname(3) can fail to access /dev/ path, and that will cause function to fail without setting errno value with result of rather confusing error message. Lets start setting stdin permission via /proc when this happens as a go-around, with hope kernel following symlink does not fail. Ok, noted, that hopes of symlink follow working are pretty slim. Based on patch from Sami Kerola <kerolasa@iki.fi>. Reference: https://github.com/lxc/lxd/issues/1724 Signed-off-by: Karel Zak <kzak@redhat.com>
* lib/ttyutils: introduce get_terminal_stdfd()Karel Zak2019-05-273-9/+21
| | | | | | Let's use separate function to detect what is the current terminal. Signed-off-by: Karel Zak <kzak@redhat.com>
* libblkid: remove unneeded fields from struct bcache_super_blockSami Kerola2019-05-271-46/+7Star
| | | | | | | | | | | | | | | | This started as fix to following warning. libblkid/src/superblocks/bcache.c:33:3: warning: ISO C99 doesn’t support unnamed structs/unions [-Wc99-c11-compat] But when sent to review Karel told out rather than getting rid of warnings lets get rid of everything unnecessary. [kzak@redhat.com: - use original struct member names rather than 'padN'] Reference: https://github.com/karelzak/util-linux/pull/802 Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* login: retire use of __FUNCTION__ macroKarel Zak2019-05-271-4/+3Star
| | | | | | | | | | | | | | This fixes following warning about deprecatd __FUNCTION__ that is another name for __func__ since GCC (pre 2.95, released July 1999). login-utils/login.c:860:10: warning: ISO C does not support ‘__FUNCTION__’ predefined identifier [-Wpedantic] Co-Author: Sami Kerola <kerolasa@iki.fi> Reference: https://c0x.coding-guidelines.com/6.4.2.2.html Reference: https://github.com/karelzak/util-linux/pull/802 Signed-off-by: Sami Kerola <kerolasa@iki.fi> Signed-off-by: Karel Zak <kzak@redhat.com>
* ipcs: check return value when read from /proc [coverity scan]Karel Zak2019-05-231-3/+6
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* hwclock: don't use uninitialized value [coverity scan]Karel Zak2019-05-231-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* fallocate: make posix_fadvise() use more readable for analyzersKarel Zak2019-05-231-2/+5
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* dmesg: make strtok() use more robustKarel Zak2019-05-231-0/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* blkzone: remove never read valueKarel Zak2019-05-231-3/+1Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* whereis: make subdirs scan more robustKarel Zak2019-05-231-10/+27
| | | | | | | | | * call strchr() only once * avoid things like strcat(buf, strchr(dir, '*') + 1) * make it more readable * improve debug messages Signed-off-by: Karel Zak <kzak@redhat.com>
* lsblk: make sure __process_one_device() has proper arguments [coverity scan]Karel Zak2019-05-231-2/+7
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lsblk: check ul_path_scanf() return value [coverity scan]Karel Zak2019-05-231-4/+5
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lsblk: check stat() return code [coverity scan]Karel Zak2019-05-231-2/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* logger: make code more robust for static analyzer [clang scan]Karel Zak2019-05-231-0/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* hardlink: avoid uninitialized variables [clang scan]Karel Zak2019-05-231-2/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libfdisk: assert if self_pte() returns NULLSami Kerola2019-05-221-0/+4
| | | | | | | | | | The self_pte() can return NULL if partitions array is not large enough, but that should also be impossible and definitely a bug. libfdisk/src/dos.c:984:8: warning: potential null pointer dereference [-Wnull-dereference] libfdisk/src/dos.c:1031:8: warning: potential null pointer dereference [-Wnull-dereference] Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* libfdisk: (bsd) improve checksum calculation [-Waddress-of-packed-member]Karel Zak2019-05-221-5/+12
| | | | | | | | Let's keep compilers and static analyzers happy. The idea is to use memcpy() to copy from buffer to variable and use all label as unsigned char rather than vectorize by unsigned short. Signed-off-by: Karel Zak <kzak@redhat.com>
* libblkid: (silicon raid) improve checksum calculation ↵Karel Zak2019-05-221-3/+7
| | | | | | | | | | [-Waddress-of-packed-member] Let's keep compilers and static analyzers happy. The idea is to use memcpy() to copy from buffer to variable and use all label as unsigned char rather than vectorize by uint16_t. Signed-off-by: Karel Zak <kzak@redhat.com>
* libfdisk: (sgi) improve checksum calculation [-Waddress-of-packed-member]Karel Zak2019-05-221-6/+11
| | | | | | | | Let's keep compilers and static analyzers happy. The idea is to use memcpy() to copy from buffer to variable and use all label as unsigned char rather than vectorize by uint32_t. Signed-off-by: Karel Zak <kzak@redhat.com>
* include/c: use __has_attributeKarel Zak2019-05-211-12/+19
| | | | | | | | | | | | | | The __has macros are more portable (supported by gcc as well as clang). The old __GNUC_PREREQ is deprecated and it should be removed in future. (Well, the __has macros are supported since gcc 5, so we should be patient as some old stable distros (e.g. RHEL 7) use gcc 4.x). This patch helps clang to correctly analyze our xalloc.h stuff. Signed-off-by: Karel Zak <kzak@redhat.com>
* bash-completion: add hardlink completionSami Kerola2019-05-201-0/+36
| | | | Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* bash-completion: update options before releaseSami Kerola2019-05-203-1/+6
| | | | | | | | | | blkid: 5e91d5dd716ebc6144bcb0cabb0ec847a678be9e --no-part-details lsblk: dc4662f0e755929de9cbe98b1b343b492fd620f4 --dedup lsblk: 0bd05f5ee4876ffd13c98acd56c2bff9971f28f1 --merge lscpu: 0e86bc8406959d0d56194d4f404b780e6b70caa4 --caches lscpu: 2011528bce58dd31d5ee0287f2367da1f2d6cfa9 --bytes Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* lib/ismounted: use xstrncpy()Karel Zak2019-05-201-4/+5
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* zramctl: use xstrncpy()Karel Zak2019-05-201-4/+2Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* whereis: use xstrncpy()Karel Zak2019-05-201-4/+2Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* vipw: use xstrncpy()Karel Zak2019-05-201-6/+6
| | | | | | It's already used by vipw, so use it everywhere. Signed-off-by: Karel Zak <kzak@redhat.com>