summaryrefslogtreecommitdiffstats
path: root/monitor
diff options
context:
space:
mode:
authorBrad Bishop <bradleyb@fuzziesquirrel.com>2017-07-30 15:42:10 -0400
committerPatrick Williams <patrick@stwcx.xyz>2017-08-03 01:52:48 +0000
commitfa0766e3b04b2832c10efbe1afcbb13ee4da4d8c (patch)
treed1844dc8e771cd7fee729b7cfc068343487f4d8e /monitor
parentedaeb31c886e2b8d2d43664ec4178c8d35094742 (diff)
downloadphosphor-fan-presence-fa0766e3b04b2832c10efbe1afcbb13ee4da4d8c.tar.gz
phosphor-fan-presence-fa0766e3b04b2832c10efbe1afcbb13ee4da4d8c.zip
monitor: Do not allow TachSensor move
TachSensor uses the this pointer as the systemd callback context for signal callbacks, which doesn't work with move semantics. Change-Id: I5e58fec9a7edfc457103d8a36f6076d90246f4f0 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Diffstat (limited to 'monitor')
-rw-r--r--monitor/tach_sensor.hpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/monitor/tach_sensor.hpp b/monitor/tach_sensor.hpp
index fbda37b..dd2222b 100644
--- a/monitor/tach_sensor.hpp
+++ b/monitor/tach_sensor.hpp
@@ -34,9 +34,11 @@ class TachSensor
TachSensor() = delete;
TachSensor(const TachSensor&) = delete;
- TachSensor(TachSensor&&) = default;
+ // TachSensor is not moveable since the this pointer is used as systemd
+ // callback context.
+ TachSensor(TachSensor&&) = delete;
TachSensor& operator=(const TachSensor&) = delete;
- TachSensor& operator=(TachSensor&&) = default;
+ TachSensor& operator=(TachSensor&&) = delete;
~TachSensor() = default;
/**
OpenPOWER on IntegriCloud