Change in libosmocore[master]: gsm23003: add osmo_imei_str_valid()

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

Vadim Yanitskiy gerrit-no-reply at lists.osmocom.org
Fri Jan 11 13:19:09 UTC 2019


Vadim Yanitskiy has posted comments on this change. ( https://gerrit.osmocom.org/12524 )

Change subject: gsm23003: add osmo_imei_str_valid()
......................................................................


Patch Set 1:

(1 comment)

https://gerrit.osmocom.org/#/c/12524/1/src/gsm/gsm23003.c
File src/gsm/gsm23003.c:

https://gerrit.osmocom.org/#/c/12524/1/src/gsm/gsm23003.c@75
PS1, Line 75: the 15th check digit is not
            :  * intended for digital transmission.
> Sure. From the mentioned spec: […]
Ok, got it!

Anyway, I think we can make this function a bit more flexible by checking the length. If strlen(imei) is 14, then just do is_n_digits(imei, ...), but if the 15th check digit is present, we could also do the verification...

What do you think?



-- 
To view, visit https://gerrit.osmocom.org/12524
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: Id2d2a3a93b033bafc74c62e15297034bf4aafe61
Gerrit-Change-Number: 12524
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder (1000002)
Gerrit-Reviewer: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-Reviewer: Vadim Yanitskiy <axilirator at gmail.com>
Gerrit-Reviewer: osmith <osmith at sysmocom.de>
Gerrit-Comment-Date: Fri, 11 Jan 2019 13:19:09 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190111/a2361ee2/attachment.htm>


More information about the gerrit-log mailing list