more warning fixes

This commit is contained in:
Mike Kinney
2022-01-24 18:39:17 +00:00
parent caaa235c5d
commit 7c362af3de
27 changed files with 74 additions and 69 deletions

View File

@@ -102,7 +102,7 @@ void Channels::initDefaultChannel(ChannelIndex chIndex)
CryptoKey Channels::getKey(ChannelIndex chIndex)
{
Channel &ch = getByIndex(chIndex);
ChannelSettings &channelSettings = ch.settings;
const ChannelSettings &channelSettings = ch.settings;
assert(ch.has_settings);
CryptoKey k;
@@ -206,7 +206,7 @@ void Channels::setChannel(const Channel &c)
const char *Channels::getName(size_t chIndex)
{
// Convert the short "" representation for Default into a usable string
ChannelSettings &channelSettings = getByIndex(chIndex).settings;
const ChannelSettings &channelSettings = getByIndex(chIndex).settings;
const char *channelName = channelSettings.name;
if (!*channelName) { // emptystring
// Per mesh.proto spec, if bandwidth is specified we must ignore modemConfig enum, we assume that in that case