[vz-dev] [volkszaehler/vzlogger] 328311: Changed mainloop end to run as long as one meter i...

Matthias Behr noreply at github.com
Wed Aug 14 21:21:48 CEST 2019


  Branch: refs/heads/master
  Home:   https://github.com/volkszaehler/vzlogger
  Commit: 328311fee3e406da94ec4634d691d384f28ff94a
      https://github.com/volkszaehler/vzlogger/commit/328311fee3e406da94ec4634d691d384f28ff94a
  Author: Matthias Behr <mbehr at mcbehr.de>
  Date:   2019-08-14 (Wed, 14 Aug 2019)

  Changed paths:
    M CMakeLists.txt
    M include/MeterMap.hpp
    M src/MeterMap.cpp
    M src/vzlogger.cpp
    M tests/mocks/mock_metermap.cpp

  Log Message:
  -----------
  Changed mainloop end to run as long as one meter is running. (#388)

* Changed mainloop end to run as long as one meter is running.

MeterMap::stopped was returning wrong value if ::cancel was called
e.g. by a signal send from systemd.
Anyhow for multiple meters the mainloop was wrong so I changed it
to run as long as one meter is still running.
Issue: #385

* Cleanup of MeterMap cancel and stopped. Rework of mainloop.

Removed MeterMap::stopped. We should only use running() and cancel().
Reworked signal handler to call only async-signal-safe functions.
Reworked mainloop to check periodically whether it should stop
and indicate this to the meters by calling cancel().

Issue: #385




More information about the volkszaehler-dev mailing list