treewide: use log_*_errno whenever %m is in the format string
authorMichal Schmidt <mschmidt@redhat.com>
Fri, 28 Nov 2014 18:29:59 +0000 (19:29 +0100)
committerMichal Schmidt <mschmidt@redhat.com>
Fri, 28 Nov 2014 18:49:27 +0000 (19:49 +0100)
commit56f64d95763a799ba4475daf44d8e9f72a1bd474
tree4c38253c718dc1972b811fa7c01ebfa3c2b7776c
parent895b3a7b44fe7ca2f260986be2a877ff56a72718
treewide: use log_*_errno whenever %m is in the format string

If the format string contains %m, clearly errno must have a meaningful
value, so we might as well use log_*_errno to have ERRNO= logged.

Using:
find . -name '*.[ch]' | xargs sed -r -i -e \
's/log_(debug|info|notice|warning|error|emergency)\((".*%m.*")/log_\1_errno(errno, \2/'

Plus some whitespace, linewrap, and indent adjustments.
139 files changed:
src/activate/activate.c
src/backlight/backlight.c
src/binfmt/binfmt.c
src/bootchart/bootchart.c
src/bootchart/store.c
src/bus-proxyd/bus-proxyd.c
src/cgls/cgls.c
src/console/consoled-terminal.c
src/core/audit-fd.c
src/core/automount.c
src/core/cgroup.c
src/core/dbus.c
src/core/device.c
src/core/execute.c
src/core/hostname-setup.c
src/core/ima-setup.c
src/core/killall.c
src/core/load-dropin.c
src/core/machine-id-setup.c
src/core/main.c
src/core/manager.c
src/core/mount-setup.c
src/core/namespace.c
src/core/path.c
src/core/selinux-access.c
src/core/shutdown.c
src/core/smack-setup.c
src/core/umount.c
src/cryptsetup/cryptsetup-generator.c
src/dbus1-generator/dbus1-generator.c
src/debug-generator/debug-generator.c
src/delta/delta.c
src/efi-boot-generator/efi-boot-generator.c
src/firstboot/firstboot.c
src/fsck/fsck.c
src/fstab-generator/fstab-generator.c
src/getty-generator/getty-generator.c
src/gpt-auto-generator/gpt-auto-generator.c
src/hibernate-resume/hibernate-resume-generator.c
src/hibernate-resume/hibernate-resume.c
src/initctl/initctl.c
src/journal-remote/journal-gatewayd.c
src/journal-remote/journal-remote-parse.c
src/journal-remote/journal-remote.c
src/journal-remote/journal-upload.c
src/journal/cat.c
src/journal/catalog.c
src/journal/coredump-vacuum.c
src/journal/coredump.c
src/journal/coredumpctl.c
src/journal/journal-authenticate.c
src/journal/journal-file.c
src/journal/journal-vacuum.c
src/journal/journal-verify.c
src/journal/journalctl.c
src/journal/journald-audit.c
src/journal/journald-console.c
src/journal/journald-kmsg.c
src/journal/journald-native.c
src/journal/journald-server.c
src/journal/journald-stream.c
src/journal/journald-syslog.c
src/journal/sd-journal.c
src/libsystemd-terminal/evcat.c
src/libsystemd-terminal/grdev-drm.c
src/libsystemd-terminal/idev-evdev.c
src/libsystemd-terminal/modeset.c
src/libsystemd-terminal/subterm.c
src/libsystemd/sd-bus/test-bus-chat.c
src/libudev/libudev-device-private.c
src/libudev/libudev-device.c
src/libudev/libudev-hwdb.c
src/libudev/libudev-monitor.c
src/locale/localectl.c
src/login/inhibit.c
src/login/logind-button.c
src/login/logind-dbus.c
src/login/logind-session.c
src/login/logind-user.c
src/login/logind.c
src/login/user-sessions.c
src/machine/machinectl.c
src/machine/machined.c
src/modules-load/modules-load.c
src/network/networkctl.c
src/nspawn/nspawn.c
src/quotacheck/quotacheck.c
src/random-seed/random-seed.c
src/rc-local-generator/rc-local-generator.c
src/remount-fs/remount-fs.c
src/reply-password/reply-password.c
src/resolve-host/resolve-host.c
src/resolve/resolved-dns-stream.c
src/resolve/resolved-manager.c
src/rfkill/rfkill.c
src/run/run.c
src/shared/ask-password-api.c
src/shared/base-filesystem.c
src/shared/capability.c
src/shared/clean-ipc.c
src/shared/conf-parser.c
src/shared/generator.c
src/shared/pager.c
src/shared/ptyfwd.c
src/shared/smack-util.c
src/shared/socket-label.c
src/shared/socket-util.c
src/shared/switch-root.c
src/shared/util.c
src/shared/watchdog.c
src/shutdownd/shutdownd.c
src/sleep/sleep.c
src/socket-proxy/socket-proxyd.c
src/sysctl/sysctl.c
src/system-update-generator/system-update-generator.c
src/systemctl/systemctl.c
src/sysusers/sysusers.c
src/sysv-generator/sysv-generator.c
src/test/test-capability.c
src/test/test-ns.c
src/timedate/timedated.c
src/timesync/timesyncd-manager.c
src/timesync/timesyncd.c
src/tmpfiles/tmpfiles.c
src/tty-ask-password-agent/tty-ask-password-agent.c
src/udev/ata_id/ata_id.c
src/udev/scsi_id/scsi_id.c
src/udev/scsi_id/scsi_serial.c
src/udev/udev-builtin-keyboard.c
src/udev/udev-ctrl.c
src/udev/udev-event.c
src/udev/udev-node.c
src/udev/udev-rules.c
src/udev/udev-watch.c
src/udev/udevadm-monitor.c
src/udev/udevadm-trigger.c
src/udev/udevd.c
src/update-utmp/update-utmp.c
src/vconsole/vconsole-setup.c