diff options
author | Andrew Jeffery <andrew@aj.id.au> | 2018-11-23 15:28:58 +1100 |
---|---|---|
committer | Vernon Mauery <vernon.mauery@linux.intel.com> | 2018-11-27 18:08:32 +0000 |
commit | b975c4051e969bdb23ef18fa97224ee4d80882c3 (patch) | |
tree | 847a92624ecbcc49a9fa9e4ca37c643dcd5560e1 /ipmid.cpp | |
parent | 1a4117b8a6163dc2596cf9302c38edfef2042738 (diff) | |
download | phosphor-host-ipmid-b975c4051e969bdb23ef18fa97224ee4d80882c3.tar.gz phosphor-host-ipmid-b975c4051e969bdb23ef18fa97224ee4d80882c3.zip |
ipmid: Use sd_event_loop()
The infinite for-loop over sd_event_run() is effectively the
implementation of sd_event_loop(). sd_event_loop() has the additional
features of terminating correctly and running exit tasks on
sd_event_exit().
Change-Id: Ib01a9b1e43891cbb65cfcab1c7a000d2a13728de
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
Diffstat (limited to 'ipmid.cpp')
-rw-r--r-- | ipmid.cpp | 12 |
1 files changed, 1 insertions, 11 deletions
@@ -693,17 +693,7 @@ int main(int argc, char* argv[]) restrictionModeIntf), handle_restricted_mode_change); - for (;;) - { - /* Process requests */ - r = sd_event_run(events, (uint64_t)-1); - if (r < 0) - { - log<level::ERR>("Failure in processing request", - entry("ERRNO=0x%X", -r)); - goto finish; - } - } + r = sd_event_loop(events); } finish: |