diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/gsm/gsm0808_utils.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gsm/gsm0808_utils.c b/src/gsm/gsm0808_utils.c index b58a4b8a..776f091d 100644 --- a/src/gsm/gsm0808_utils.c +++ b/src/gsm/gsm0808_utils.c @@ -210,7 +210,7 @@ static uint8_t enc_speech_codec(struct msgb *msg, case GSM0808_SCT_FR3: case GSM0808_SCT_HR3: case GSM0808_SCT_HR6: - msgb_put_u16(msg, sc->cfg); + msgb_put_u16(msg, osmo_ntohs(sc->cfg)); break; case GSM0808_SCT_FR4: case GSM0808_SCT_FR5: @@ -320,7 +320,7 @@ int gsm0808_dec_speech_codec(struct gsm0808_speech_codec *sc, case GSM0808_SCT_HR6: if (len < 2) return -EINVAL; - sc->cfg = osmo_load16be(elem); + sc->cfg = osmo_load16le(elem); elem += 2; break; default: |