Initialize m_value in StateVariable ctor
From: Erik Hovland <erik@hovland.org>
eventing.h in libmythupnp needs to be initialized in the ctor of
StateVariable. It is in one ctor, but not the other.
---
mythtv/libs/libmythupnp/eventing.h | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/mythtv/libs/libmythupnp/eventing.h b/mythtv/libs/libmythupnp/eventing.h
index b245f37..0385cda 100644
a
|
b
|
class StateVariable : public StateVariableBase |
137 | 137 | |
138 | 138 | // ------------------------------------------------------------------ |
139 | 139 | |
140 | | StateVariable( const QString &sName, bool bNotify = false ) : StateVariableBase( sName, bNotify ) |
| 140 | StateVariable( const QString &sName, bool bNotify = false ) : StateVariableBase( sName, bNotify ), m_value( T( ) ) |
141 | 141 | { |
142 | 142 | } |
143 | 143 | |
144 | 144 | // ------------------------------------------------------------------ |
145 | 145 | |
146 | | StateVariable( const QString &sName, T value, bool bNotify = false ) : StateVariableBase( sName, bNotify ) |
| 146 | StateVariable( const QString &sName, T value, bool bNotify = false ) : StateVariableBase( sName, bNotify ), m_value(value) |
147 | 147 | { |
148 | | m_value = value; |
149 | 148 | } |
150 | 149 | |
151 | 150 | // ------------------------------------------------------------------ |