silence warning

the 'done' flag avoids actual use of uninitialized 'size'.
This commit is contained in:
Michael Davidsaver
2017-11-28 15:44:46 -06:00
parent e61d10200e
commit d4eb31e729

View File

@@ -2182,11 +2182,11 @@ public:
// defaults to queueSize/2
m_ackAny = m_queueSize/2;
bool done = false;
int32 size;
option = pvOptions->getSubField<PVScalar>("ackAny");
if (option) {
bool done = false;
int32 size = -1; /* -1 only to silence warning, should never be used */
if(option->getScalar()->getScalarType()==pvString) {
std::string sval(option->getAs<std::string>());