weston/libweston
Antonio Borneo 611fe36d24 log: remove "%m" from format strings by using strerror(errno)
The printf() format specifier "%m" is a glibc extension to print
the string returned by strerror(errno). While supported by other
libraries (e.g. uClibc and musl), it is not widely portable.

In Weston code the format string is often passed to a logging
function that calls other syscalls before the conversion of "%m"
takes place. If one of such syscall modifies the value in errno,
the conversion of "%m" will incorrectly report the error string
corresponding to the new value of errno.

Remove all the occurrences of the specifier "%m" in Weston code
by using directly the string returned by strerror(errno).
While there, fix some minor indentation issue.

Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
(cherry picked from commit 3957863667)
2019-06-19 07:44:51 +00:00
..
animation.c build,libweston: Use struct timespec for animations 2017-11-27 11:41:17 +02:00
bindings.c libweston: Use struct timespec for touch down events 2017-11-27 11:42:07 +02:00
clipboard.c include stdint.h for int32_t/uint32_t 2016-07-26 16:26:08 -07:00
compositor-drm.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
compositor-drm.h compositor-drm: Add Support virtual output 2018-10-30 17:09:01 +09:00
compositor-fbdev.c libweston: fbdev: Force the Framebuffer devices to be activated. 2019-01-31 09:46:42 +00:00
compositor-fbdev.h compositor-fbdev: support the --seat option, (and XDG_SEAT variable) 2018-07-02 15:29:38 +03:00
compositor-headless.c libweston: Introduce zwp_linux_explicit_synchronization_v1 2019-02-06 12:21:56 +00:00
compositor-headless.h weston: Store use_pixman as bool type 2019-01-31 08:57:54 +00:00
compositor-rdp.c rdp-compositor: fix compilation with FreeRDP 2.0-rc4 2018-12-04 23:42:27 +01:00
compositor-rdp.h weston: Port RDP backend to new output handling API 2016-10-03 14:24:08 +03:00
compositor-wayland.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
compositor-wayland.h compositor-wayland: Convert fullscreen flag to bool 2016-10-14 10:42:17 +02:00
compositor-x11.c libweston: Support zwp_surface_synchronization_v1.set_acquire_fence 2019-02-06 12:21:56 +00:00
compositor-x11.h weston: Port X11 backend to new output handling API 2016-10-05 14:59:09 +03:00
compositor.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
compositor.h data-device: send INVALID_FINISH when operation != dnd 2019-06-19 07:44:51 +00:00
data-device.c data-device: send INVALID_FINISH when operation != dnd 2019-06-19 07:44:51 +00:00
dbus.c include stdint.h for int32_t/uint32_t 2016-07-26 16:26:08 -07:00
dbus.h Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
git-version.h.meson Add Meson build system 2018-12-09 14:50:54 +02:00
gl-renderer.c libweston: Support zwp_surface_synchronization_v1.get_release 2019-02-06 12:21:56 +00:00
gl-renderer.h gl-renderer: provide fence sync fd for synchronizing with GPU rendering 2018-10-30 17:09:01 +09:00
input.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
launcher-direct.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
launcher-impl.h libweston: remove restore functionality 2018-02-09 15:16:07 +00:00
launcher-logind.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
launcher-util.c launcher-logind: only get a VT on seat0, as only seat0 supports VTs 2018-07-02 15:29:38 +03:00
launcher-util.h libweston: remove restore functionality 2018-02-09 15:16:07 +00:00
launcher-weston-launch.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
libbacklight.c Switch to use safe_strtoint instead of strtol 2016-08-06 18:19:22 -07:00
libbacklight.h Fix typos all around (thanks codespell!) 2019-02-20 16:47:35 +01:00
libinput-device.c libweston: introduce notify_touch_normalized() and doc 2018-05-30 14:46:05 +03:00
libinput-device.h input: introduce weston_touch_device 2018-05-30 14:42:13 +03:00
libinput-seat.c Fix typos all around (thanks codespell!) 2019-02-20 16:47:35 +01:00
libinput-seat.h libweston: require connected heads for input devices 2018-04-20 15:27:54 +03:00
libweston-protocols.pc.in protocol: add weston-debug.xml 2018-09-11 15:24:46 +01:00
libweston-uninstalled.pc.in buildsystem: add missing pkg-config stub for libweston uninstalled 2017-11-10 12:50:41 -06:00
libweston.pc.in libweston: fix major in libweston.pc 2016-08-02 14:19:11 +03:00
linux-dmabuf.c linux-dmabuf: send deprecated format events 2018-01-18 11:24:19 +00:00
linux-dmabuf.h linux-dmabuf: send deprecated format events 2018-01-18 11:24:19 +00:00
linux-explicit-synchronization.c libweston: Support zwp_surface_synchronization_v1.get_release 2019-02-06 12:21:56 +00:00
linux-explicit-synchronization.h libweston: Support zwp_surface_synchronization_v1.set_acquire_fence 2019-02-06 12:21:56 +00:00
linux-sync-file-uapi.h libweston: Introduce an internal linux sync file API 2019-02-06 12:21:56 +00:00
linux-sync-file.c libweston: Introduce an internal linux sync file API 2019-02-06 12:21:56 +00:00
linux-sync-file.h libweston: Introduce an internal linux sync file API 2019-02-06 12:21:56 +00:00
log.c log: improve handling of use-before-init 2018-05-28 16:38:05 +03:00
meson.build meson.build/libweston: Fix clang warning for export-dynamic 2019-06-18 23:39:13 +03:00
noop-renderer.c include stdint.h for int32_t/uint32_t 2016-07-26 16:26:08 -07:00
pixel-formats.c Fix typos all around (thanks codespell!) 2019-02-20 16:47:35 +01:00
pixel-formats.h pixel-formats: Added pixel_format_get_info_shm() helper for printing SHM buffers 2018-11-20 18:00:09 +02:00
pixman-renderer.c libweston: Support zwp_surface_synchronization_v1.get_release 2019-02-06 12:21:56 +00:00
pixman-renderer.h pixman: make shadow buffer optional 2018-05-24 17:20:04 +03:00
plugin-registry.c compositor: add plugin-registry 2016-07-01 14:10:26 +03:00
plugin-registry.h compositor: add plugin-registry 2016-07-01 14:10:26 +03:00
screenshooter.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
spring-tool.c build,libweston: Use struct timespec for animations 2017-11-27 11:41:17 +02:00
timeline-object.h Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
timeline.c file-util: allow specifying path separately in file_create_dated() 2018-02-09 15:16:07 +00:00
timeline.h timeline: Add GPU timestamp timepoint argument 2017-09-29 10:20:42 +03:00
touch-calibration.c libweston: implement touch calibration protocol 2018-05-30 14:46:24 +03:00
vaapi-recorder.c Fix typos all around (thanks codespell!) 2019-02-20 16:47:35 +01:00
vaapi-recorder.h Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
version.h.in Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
vertex-clipping.c Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
vertex-clipping.h Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
weston-debug.c Fix typos all around (thanks codespell!) 2019-02-20 16:47:35 +01:00
weston-debug.h libweston/weston-debug: Add a easy way to determine if the debug protocol has been enabled 2018-12-18 15:37:34 +02:00
weston-launch.c log: remove "%m" from format strings by using strerror(errno) 2019-06-19 07:44:51 +00:00
weston-launch.h Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
windowed-output-api.h libweston: change windowed_output_api output_create to create_head 2018-04-17 15:19:57 +03:00
zoom.c libweston: Make weston_pointer destruction safe 2018-02-14 15:14:16 +02:00