Change in libosmocore[master]: Fix BSSMAP length generated by gsm0808_create_clear_command2()

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Mon Feb 18 12:48:05 UTC 2019


Harald Welte has posted comments on this change. ( https://gerrit.osmocom.org/12924 )

Change subject: Fix BSSMAP length generated by gsm0808_create_clear_command2()
......................................................................


Patch Set 1:

(1 comment)

https://gerrit.osmocom.org/#/c/12924/1/src/gsm/gsm0808.c
File src/gsm/gsm0808.c:

https://gerrit.osmocom.org/#/c/12924/1/src/gsm/gsm0808.c@200
PS1, Line 200: 	msgb_v_put(msg, BSS_MAP_MSG_CLEAR_CMD);
> In the commit description you state you are fixing some length, but I also see some parts of this me […]
please note the sublte difference of first putting and then pushing at the end.  So the order in the code is reversed, but the order of the message is not.  Adding the header at the end alows us to use msgb_length(msg) for dynamically computing the length, which is exactly what prevents this kind of bug (hard-coded length values at start of message generation).



-- 
To view, visit https://gerrit.osmocom.org/12924
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I4d07d25fb03ca0f89fd7b94226c54309c77a010a
Gerrit-Change-Number: 12924
Gerrit-PatchSet: 1
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder (1000002)
Gerrit-CC: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-Comment-Date: Mon, 18 Feb 2019 12:48:05 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190218/0f849da1/attachment.htm>


More information about the gerrit-log mailing list