1
0
mirror of https://github.com/fwbuilder/fwbuilder synced 2026-05-10 11:05:06 +02:00

refactor: Initialize variables

This commit is contained in:
Sirius Bakke
2018-10-04 16:20:01 +02:00
parent 0cf32a26b5
commit a33f73b394
4 changed files with 4 additions and 4 deletions

View File

@@ -180,7 +180,7 @@ eth4 Link encap:Ethernet HWaddr 00:0C:29:F6:BE:BE
for (intf=it->second.begin(); intf!=it->second.end(); ++intf)
{
linux24Interfaces::interface_type itype;
linux24Interfaces::interface_type itype{};
if ((*intf)->name.find("bond") == 0 &&
(*intf)->name.find(".") == string::npos)

View File

@@ -957,7 +957,7 @@ void PIXImporter::commitNamedICMPServiceObject()
void PIXImporter::commitNamedTCPUDPServiceObject()
{
FWObject *obj;
FWObject *obj = nullptr;
// have to use createTCPService because it processes "neq" port
// operators and may create a group with two services nstead of
// just tcp service. Same for udp.

View File

@@ -155,7 +155,7 @@ vector<FWObject*> fwcompiler::_find_srv_intersection(Service *op1, Service *op2)
if ( ! _find_portrange_intersection(srs1,sre1,srs2,sre2,srsR,sreR) ) return res;
if ( ! _find_portrange_intersection(drs1,dre1,drs2,dre2,drsR,dreR) ) return res;
FWObject *nserv;
FWObject *nserv = nullptr;
if ( TCPService::cast(op1) )
{
nserv=new TCPService();

View File

@@ -159,7 +159,7 @@ void RuleSetDiffDialog::updateRuleSetView() {
if (!currentRuleSet || !originalRuleSet) return;
RuleSetModel *currentRuleSetModel, *originalRuleSetModel;
RuleSetModel *currentRuleSetModel = nullptr, *originalRuleSetModel = nullptr;
if (Policy::isA(currentRuleSet)) {
currentRuleSetModel = new PolicyModel(Policy::cast(currentRuleSet), this);