Change in osmo-bsc[master]: bty_vty: add VTY settungs for temporary overpower

laforge gerrit-no-reply at lists.osmocom.org
Tue Aug 31 19:53:02 UTC 2021


laforge has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/25283 )

Change subject: bty_vty: add VTY settungs for temporary overpower
......................................................................


Patch Set 2: Code-Review-1

(1 comment)

https://gerrit.osmocom.org/c/osmo-bsc/+/25283/2/src/osmo-bsc/abis_rsl.c 
File src/osmo-bsc/abis_rsl.c:

https://gerrit.osmocom.org/c/osmo-bsc/+/25283/2/src/osmo-bsc/abis_rsl.c@563 
PS2, Line 563: cap = (struct abis_rsl_osmo_temp_ovp_acch_cap *)msg->tail;
you are getting a pointer to the end of the used part of the message buffer.  this basically is where you will store the TAG in the line below.

so now you have a pointer to the TAG but later dereference it as a struct and set it to 0.  There's a reason why meddling with msgb "internal" pointers is mostly not a good idea.  Application code should only use the provided functions, macros and return values.

I think the proper approach here is to copy your bts->temporary_overpower to a local stack variable, and then set that to 0 or not _before_ the msgb_tlv_put



-- 
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/25283
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: I488a91bb4ed86f630db56564a0cd293f39f0f690
Gerrit-Change-Number: 25283
Gerrit-PatchSet: 2
Gerrit-Owner: dexter <pmaier at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Comment-Date: Tue, 31 Aug 2021 19:53:02 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210831/9171967b/attachment.htm>


More information about the gerrit-log mailing list