On Wed, Feb 19, 2014 at 07:57:53AM +0100, Andreas Eversberg wrote:
The patch does not do what the subject is saying. This implements the AMR frame handling. It is a bit unfortunate that NITB is now announcing version4 and not all new features are implemented yet. This somehow defeats the purpose of versioning the protocol. I don't know if you remember but I added the version number as I was trying to figure out why NITB/LCR didn't work together...
- int is_amr = 0;
by your choice of name you indicate this is a boolean.
- if (is_amr)
frame->data[0] = payload_len;- memcpy(frame->data + is_amr, payload, payload_len);
- msgb_put(new_msg, sizeof(struct gsm_data_frame) + is_amr + payload_len);
here you use it like an int/offset. What about using the msgg routines from the tlv.h code to append the value and data?
- int is_amr = 0;
same
- memcpy(msg->data + sizeof(struct rtp_hdr), frame->data + is_amr,
payload_len);
same issue here with boolean.