Merge pull request #1922 from PhenomRetroShare/Fix_SomeWarnings

Fix some warnings
This commit is contained in:
csoler 2020-05-12 23:05:34 +02:00 committed by GitHub
commit e6edae27be
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 72 additions and 68 deletions

View File

@ -90,7 +90,7 @@ void RsMsgTags::serial_process(RsGenericSerializer::SerializeJob j,RsGenericSeri
if(j == RsGenericSerializer::DESERIALIZE)
while(ctx.mOffset < ctx.mSize)
{
uint32_t n ;
uint32_t n = 0;// No real need to initialize but otherwise the compiler complains.
RsTypeSerializer::serial_process<uint32_t>(j,ctx,n,"tagIds element") ;
tagIds.push_back(n) ;
}

View File

@ -322,7 +322,7 @@ void IdDetailsDialog::modifyReputation()
case 2: op = RsOpinion::POSITIVE; break;
default:
std::cerr << "Wrong value from opinion combobox. Bug??" << std::endl;
break;
return;
}
rsReputations->setOwnOpinion(id,op);

View File

@ -681,6 +681,7 @@ QVariant RsFriendListModel::displayRole(const EntryIndex& e, int col) const
break;
case ENTRY_TYPE_NODE:
{
const HierarchicalNodeInformation *node = getNodeInfo(e);
if(!node)
@ -710,7 +711,10 @@ QVariant RsFriendListModel::displayRole(const EntryIndex& e, int col) const
default:
return QVariant();
} break;
}
break;
default: //ENTRY_TYPE
return QVariant();
}
}