diff options
author | Matthias P. Braendli <matthias.braendli@mpb.li> | 2019-07-05 11:39:10 +0200 |
---|---|---|
committer | Matthias P. Braendli <matthias.braendli@mpb.li> | 2019-07-05 11:39:10 +0200 |
commit | 1efc52d414887d568e9af709795169ae0e3f8cc4 (patch) | |
tree | 9ad1b5819aeceaab36393aeea49f7e3816266c49 | |
parent | ba80e0070452f7f6c7ee64d1d5b037f100c0484a (diff) | |
download | glutte-o-matic-1efc52d414887d568e9af709795169ae0e3f8cc4.tar.gz glutte-o-matic-1efc52d414887d568e9af709795169ae0e3f8cc4.tar.bz2 glutte-o-matic-1efc52d414887d568e9af709795169ae0e3f8cc4.zip |
Suppress warning in cw.c
-rw-r--r-- | src/common/Audio/cw.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/common/Audio/cw.c b/src/common/Audio/cw.c index e7cc806..84e96a4 100644 --- a/src/common/Audio/cw.c +++ b/src/common/Audio/cw.c @@ -425,8 +425,9 @@ static size_t psk_text_to_phase_buffer(const char* instr, uint8_t* outbits) /* Encode the message, with 00 between letters */ for (j=0; j < strlen(instr); j++) { - if (instr[j] < sizeof(psk_varicode)) { - const char* varicode_bits = psk_varicode[(int)instr[j]]; + const uint16_t ix = instr[j]; + if (ix < sizeof(psk_varicode)) { + const char* varicode_bits = psk_varicode[ix]; for(k=0; k < strlen(varicode_bits); k++) { outbits[i++] = (varicode_bits[k] == '1') ? 1 : 0; } |