Change in libosmocore[master]: gsm48: add compare function for struct gprs_ra_id

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/.

pespin gerrit-no-reply at lists.osmocom.org
Thu Feb 4 10:25:54 UTC 2021


pespin has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmocore/+/22669 )

Change subject: gsm48: add compare function for struct gprs_ra_id
......................................................................


Patch Set 1: Code-Review-1

(1 comment)

https://gerrit.osmocom.org/c/libosmocore/+/22669/1/src/gsm/gsm48.c 
File src/gsm/gsm48.c:

https://gerrit.osmocom.org/c/libosmocore/+/22669/1/src/gsm/gsm48.c@1305 
PS1, Line 1305: int gsm48_compare_ra(const struct gprs_ra_id *raid1, const struct gprs_ra_id *raid2)
> I think checking for equality like you did is okay in this case, but I would rename the function sin […]
Agree, either call it _equal() and return bool or _cmp() and return -1|0|1.

If you want to compare only the LAI bits, I'd add an extra API gsm48_ra_cmp_lai() which at the same time can be reused by gsm48_ra_cmp() internally.



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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I4d7558c04d9d01761516526086be5104bb2eeada
Gerrit-Change-Number: 22669
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-CC: daniel <dwillmann at sysmocom.de>
Gerrit-Comment-Date: Thu, 04 Feb 2021 10:25:54 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: daniel <dwillmann at sysmocom.de>
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210204/7609ca04/attachment.htm>


More information about the gerrit-log mailing list