Fix encoding of BSSGP_IE_NUM_OCT_AFF in bssgp_tx_llc_discarded()

This is a 24bit integer value, and thus we need to encode the three
least significant octets of the network-byte-order 32bit value, not the
three most significant octets.
This commit is contained in:
Andreas Eversberg 2012-07-21 13:33:39 +02:00 committed by Harald Welte
parent 007a71e332
commit aa5d0e8894
1 changed files with 1 additions and 1 deletions

View File

@ -230,7 +230,7 @@ int bssgp_tx_llc_discarded(struct bssgp_bvc_ctx *bctx, uint32_t tlli,
msgb_tvlv_put(msg, BSSGP_IE_LLC_FRAMES_DISCARDED, 1, &num_frames);
msgb_tvlv_put(msg, BSSGP_IE_BVCI, 2, (uint8_t *) &_bvci);
msgb_tvlv_put(msg, BSSGP_IE_NUM_OCT_AFF, 3, (uint8_t *) &_oct_aff);
msgb_tvlv_put(msg, BSSGP_IE_NUM_OCT_AFF, 3, ((uint8_t *) &_oct_aff) + 1);
return gprs_ns_sendmsg(bssgp_nsi, msg);
}