libvirt/src/logging
Michal Privoznik 857df2fe50 lib: Drop intermediary return variables
In a few places we declare a variable (which is optionally
followed by a code not touching it) then set the variable to a
value and return the variable immediately. It's obvious that the
variable is needless and the value can be returned directly
instead.

This patch was generated using this semantic patch:

  @@
  type T;
  identifier ret;
  expression E;
  @@
  - T ret;
  ... when != ret
      when strict
  - ret = E;
  - return ret;
  + return E;

After that I fixed couple of formatting issues because coccinelle
formatted some lines differently than our coding style.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
2021-10-25 12:48:46 +02:00
..
log_daemon_config.c
log_daemon_config.h
log_daemon_dispatch.c
log_daemon_dispatch.h
log_daemon.c lib: Drop intermediary return variables 2021-10-25 12:48:46 +02:00
log_daemon.h
log_handler.c util: alloc: Reimplement VIR_APPEND_ELEMENT_COPY using virAppendElement 2021-08-06 08:53:25 +02:00
log_handler.h
log_manager.c rpc: remove "spawnDaemon" parameter 2021-06-04 11:42:59 +01:00
log_manager.h logging: define cleanup func for virLogManager 2021-10-12 14:12:11 +02:00
log_protocol.x
meson.build
test_virtlogd.aug.in
virtlogd-admin.socket.in
virtlogd.aug
virtlogd.conf
virtlogd.init.in
virtlogd.service.in
virtlogd.socket.in
virtlogd.sysconf