summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* docs: tweak the grammar of an agetty man-page fragmentBenno Schulenberg2013-10-041-4/+4
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* libfdisk: improve spelling of two commentsBenno Schulenberg2013-10-041-2/+2
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* agetty: use standard angular brackets in usage messageBenno Schulenberg2013-10-041-2/+2
| | | | Signed-off-by: Benno Schulenberg <bensberg@justemail.net>
* build-sys: Fix check for __GNU_LIBRARY__Michael Forney2013-10-041-1/+1
| | | | | | | If we are not on glibc, __GNU_LIBRARY__ will not exist causing the check to always fail and try to use syscalls directly. Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: Check for type sighandler_t and use if presentMichael Forney2013-10-042-1/+9
| | | | | | | __sighandler_t is libc implementation specific and should not be relied upon. Instead, we fall back upon void (*)(int), as specified by POSIX. Signed-off-by: Karel Zak <kzak@redhat.com>
* include: Add missing includesMichael Forney2013-10-044-0/+6
| | | | | | | | sys/types.h: For u_char typedef sys/params.h: For MAXNAMLEN sys/ttydefaults.h: For various tty definitions (also add configure check) Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: Use _POSIX_VERSION to determine support for %mMichael Forney2013-10-041-1/+7
| | | | | | | %m is included in POSIX 2008, so we can check if the libc implements that before failing. Signed-off-by: Karel Zak <kzak@redhat.com>
* testsL fix py<libname> checkKarel Zak2013-10-031-1/+1
| | | | | Reported-by: Bruce Dubbs <bruce.dubbs@gmail.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* su: fix caught_signal logic and initialize oldact [coverity scan]Karel Zak2013-10-021-0/+5
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* fdisk: fix possible memleak [coverity scan]Karel Zak2013-10-021-3/+6
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lscpu: cleanup DMI code [coverity scan]Karel Zak2013-10-022-37/+42
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* docs: update TODOKarel Zak2013-10-021-25/+4Star
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lscpu: check strchr() result [coverity scan]Karel Zak2013-10-011-0/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* lscpu: don't pass null pointer to string functions [coverity scan]Karel Zak2013-10-011-3/+4
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: remove dead code [coverity scan]Karel Zak2013-10-011-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libblkid: use proper type in xfs log checker [coverity scan]Karel Zak2013-10-011-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* pylibmount: check for mnt_fs_get_tag() return value [coverity scan]Karel Zak2013-10-011-1/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* pylibmount: make tab parsers more robust [coverity scan]Karel Zak2013-10-011-3/+3
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* utmpdump: make analyzers happyKarel Zak2013-10-011-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* last: check fstat() return [coverity scan]Karel Zak2013-10-011-1/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: make mnt_table_replace_file() more robust [coverity scan]Karel Zak2013-10-011-1/+13
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* fsck: don't print warning if there is no /etc/fstab at allKarel Zak2013-10-011-4/+8
| | | | | Reported-by: Thomas Bächler <thomas@archlinux.org> Signed-off-by: Karel Zak <kzak@redhat.com>
* losetup: don't require 512-byte aligned offsetsKarel Zak2013-10-012-5/+7
| | | | | | | | | | | | | | | | Kernel aligns the device size, but the offset where the device starts is not required to be aligned. # losetup --offset 32 -f file.img is just fine, the final size of the look device will be (in sectors) (backing_file_size - offset) >> 9 so we have to do the same in userspace when we check for successful set capacity ioctl. Signed-off-by: Karel Zak <kzak@redhat.com>
* Merge branch 'master' of https://github.com/yurchor/util-linuxKarel Zak2013-09-306-7/+7
|\
| * Fix various typosYuri Chornoivan2013-09-286-10/+10
| |
* | bash-completion: use '\n' as IFS when ask for filenamesKarel Zak2013-09-3046-0/+49
| | | | | | | | | | | | | | | | | | | | | | | | The bash completion for more(1) treats the space-separated pieces of filenames as different files. $ touch foo\ bar $ more foo<TAB> bar foo Reported-by: Ángel González <ingenit@zoho.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* | textual: fix misspelled words in -rc1Karel Zak2013-09-304-9/+11
| | | | | | | | | | Reported-by: Rafael Ferreira <rafael.f.f1@gmail.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* | libmount: Save errno if mkostemp() failedNamhyung Kim2013-09-301-1/+3
| | | | | | | | | | | | | | | | After mkostemp() failed, umask() and free() might alter the errno to another value. Not sure those calls really changes the errno or not. But let's be more conservative. Signed-off-by: Namhyung Kim <namhyung@gmail.com>
* | build-sys: simplify python detectionSami Kerola2013-09-301-12/+7Star
| | | | | | | | | | | | | | | | This allows './configure --enable-most-builds' and 'make distcheck' to work when both python2 and python3 are installed, and user has set python version preference using symlink and PATH order. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
* | clean up term lib handlingMike Frysinger2013-09-305-52/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The ncurses package has been providing pkg-config files for a while now. So let's start using them to get the proper linker & compiler flags. It can make a difference when ncurses is configured in a way that requires extra link time flags but util-linux doesn't provide them, or when the headers live in a weird place and util-linux can't find them. Since the NCURSES_LIBS is always defined for the Makefile, there's no need to gate on the HAVE_NCURSES conditional. When it's disabled, the var will simply be empty. With a minor tweak to how tinfo is handled, we can do the same thing -- we just always use TINFO_LIBS in the Makefile's. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* | setterm: fix term.h/ncurses.h include orderingMike Frysinger2013-09-301-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The ncurses term.h header has logic in it to detect if nucrses.h has already been included and void defining things when it has. But since setterm includes term.h and the ncurses.h, it doesn't work and we can get fun build-time warnings like: CC term-utils/setterm-setterm.o In file included from term-utils/setterm.c:109:0: /usr/include/ncursesw/ncurses.h:827:12: warning: redundant redeclaration of 'tigetflag' [-Wredundant-decls] extern NCURSES_EXPORT(int) tigetflag (NCURSES_CONST char *); /* implemented */ ^ In file included from term-utils/setterm.c:106:0: /usr/include/ncursesw/term.h:775:12: note: previous declaration of 'tigetflag' was here extern NCURSES_EXPORT(int) tigetflag (NCURSES_CONST char *); ^ Signed-off-by: Mike Frysinger <vapier@gentoo.org>
* | findmnt: always allocate memory for cell valueDave Reisner2013-09-301-1/+1
| | | | | | | | | | | | | | Since b3386c83fe77, findmnt's output uses TT_FL_FREEDATA, which causes a crash here when string literal is returned instead of a heap address. Signed-off-by: Dave Reisner <dreisner@archlinux.org>
* | nologin: add new commandKarel Zak2013-09-307-0/+150
|/ | | | | | | Currently it's maintained as distro specific (or people use impolite /bin/false way). Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: release++ (v2.24-rc1)Karel Zak2013-09-271-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* docs: update v2.24-ReleaseNotesKarel Zak2013-09-271-1/+13
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: one install dir for all pylibmount stuffKarel Zak2013-09-273-5/+10
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: fix lastb symlinkKarel Zak2013-09-271-1/+1
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* po: merge changesKarel Zak2013-09-2727-621/+621
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* tests: update build testsKarel Zak2013-09-2718-18/+50
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: fix static buildsKarel Zak2013-09-271-4/+6
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libblkid: update docsKarel Zak2013-09-272-0/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: update docsKarel Zak2013-09-274-7/+7
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* umount: provide more helpful error messageKarel Zak2013-09-271-0/+6
| | | | | | | | | | | | | | | non-root user on device that is not mounted: $ umount /mnt/flash umount: /mnt/flash: umount failed: Operation not permitted this is true, because we cannot evaluate permissions as there is no entry in mtab, but users expect something more helpful -- for example umount: /mnt/flash: not mounted References: https://bugs.archlinux.org/task/31647 Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: small cleanup in umount codeKarel Zak2013-09-272-3/+6
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* docs: add v2.24-ReleaseNotesKarel Zak2013-09-261-0/+784
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* mount: add notes about UUIDs to the man pageKarel Zak2013-09-262-3/+9
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* libmount: compose mount.<type> helpers paths more carefullyKarel Zak2013-09-261-0/+1
| | | | | | | | | | | | | | | | | | | | The [u]mount helper path is "/sbin/mount.<type>", the <type> should not be possible to interpret like a path, for example: # mkdir /sbin/mount.fake # mount -t fake/../../../home/user/foo.sh Anyway, this is *not mount(8) security issue*, because: - non-root users don't have permissions to specify -t on mount(8) command line - /sbin is not writable for regular users This patch makes libmount more robust for situations when the library is used by incompetent developers who don't sanitize user's input. Reported-by: "Horsfall, Matthew" <mhorsfal@akamai.com> Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: add pylibmount __init__.py EXTRA_DISTKarel Zak2013-09-261-0/+2
| | | | Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: fix ${prefix} usage, be more verbose about py pathsKarel Zak2013-09-261-7/+11
| | | | | | | | | | | - incorrect ${prefix} and ${exec_prefix} usage in AC_CASE (bug introduced by commit 9f57e6e8) - disable python by default (you have to use --with-python) - add python paths to the finale ./configure info message Signed-off-by: Karel Zak <kzak@redhat.com>
* build-sys: install to the correct python dirsKarel Zak2013-09-262-3/+4
| | | | | | | It seems we have to call AM_PATH_PYTHON() monster to get pyexec (shared libs) and python (scripts) directories. Signed-off-by: Karel Zak <kzak@redhat.com>