Skip to content

Commit 6b4d7c5

Browse files
committed
piss everyone off and properly relabel "enabled" options to "enable" to keep project consistency;
1 parent ff3733f commit 6b4d7c5

2 files changed

Lines changed: 9 additions & 9 deletions

File tree

configs/fne-config.example.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ master:
128128
#
129129
crypto_container:
130130
# Flag indicating whether or not crypto services are enabled.
131-
enabled: false
131+
enable: false
132132
# Full path to the talkgroup rules file.
133133
file: key_container.ekc
134134
# Container password.
@@ -151,7 +151,7 @@ master:
151151
peers:
152152
- name: EXAMPLEPEER
153153
# Flag indicating whether or not the peer is enabled.
154-
enabled: true
154+
enable: true
155155
# Hostname/IP address of the FNE master to connect to.
156156
masterAddress: 127.0.0.1
157157
# Port number of the FNE master to connect to.
@@ -246,7 +246,7 @@ system:
246246
#
247247
peer_acl:
248248
# Flag indicating whether or not the peer ACLs are enabled.
249-
enabled: false
249+
enable: false
250250
# Peer ACL mode: whitelist or blacklist
251251
mode: whitelist
252252
# Full path to the white/blacklist file.
@@ -260,7 +260,7 @@ system:
260260
vtun:
261261
# Flag indicating the virtual network tunnel is enabled.
262262
# (If this is enabled, dvmfne must be run as root to create the TUN interface.)
263-
enabled: false
263+
enable: false
264264
# Operational mode for the network tunnel (dmr or p25).
265265
digitalMode: p25
266266

src/fne/HostFNE.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,7 @@ bool HostFNE::readParams()
362362
uint32_t talkgroupConfigReload = talkgroupRules["time"].as<uint32_t>(30U);
363363

364364
yaml::Node cryptoContainer = masterConf["crypto_container"];
365-
bool cryptoContainerEnabled = cryptoContainer["enabled"].as<bool>(false);
365+
bool cryptoContainerEnabled = cryptoContainer["enable"].as<bool>(false);
366366
#if !defined(ENABLE_TCP_SSL)
367367
cryptoContainerEnabled = false;
368368
#endif // ENABLE_TCP_SSL
@@ -371,7 +371,7 @@ bool HostFNE::readParams()
371371
uint32_t cryptoContainerReload = cryptoContainer["time"].as<uint32_t>(30U);
372372

373373
std::string peerListLookupFile = systemConf["peer_acl"]["file"].as<std::string>();
374-
bool peerListLookupEnable = systemConf["peer_acl"]["enabled"].as<bool>(false);
374+
bool peerListLookupEnable = systemConf["peer_acl"]["enable"].as<bool>(false);
375375
std::string peerListModeStr = systemConf["peer_acl"]["mode"].as<std::string>("whitelist");
376376
uint32_t peerListConfigReload = systemConf["peer_acl"]["time"].as<uint32_t>(30U);
377377

@@ -735,7 +735,7 @@ bool HostFNE::createPeerNetworks()
735735
for (size_t i = 0; i < peerList.size(); i++) {
736736
yaml::Node& peerConf = peerList[i];
737737

738-
bool enabled = peerConf["enabled"].as<bool>(false);
738+
bool enabled = peerConf["enable"].as<bool>(false);
739739
std::string masterAddress = peerConf["masterAddress"].as<std::string>();
740740
uint16_t masterPort = (uint16_t)peerConf["masterPort"].as<uint32_t>(TRAFFIC_DEFAULT_PORT);
741741
std::string password = peerConf["password"].as<std::string>();
@@ -835,7 +835,7 @@ bool HostFNE::createVirtualNetworking()
835835
{
836836
yaml::Node vtunConf = m_conf["vtun"];
837837
#if !defined(_WIN32)
838-
bool vtunEnabled = vtunConf["enabled"].as<bool>(false);
838+
bool vtunEnabled = vtunConf["enable"].as<bool>(false);
839839
if (vtunEnabled) {
840840
m_vtunEnabled = vtunEnabled;
841841

@@ -1049,4 +1049,4 @@ void HostFNE::processPeer(network::PeerNetwork* peerNetwork)
10491049
m_network->nxdnTrafficHandler()->processFrame(data.get(), length, peerId, peerNetwork->pktLastSeq(), streamId, true);
10501050
}
10511051
}
1052-
}
1052+
}

0 commit comments

Comments
 (0)