Change in osmo-pcu[master]: csn1: fix csnStreamEncoder(): do not suppress 'no space' errors

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

fixeria gerrit-no-reply at lists.osmocom.org
Sat Mar 7 08:31:41 UTC 2020


fixeria has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/17394 )

Change subject: csn1: fix csnStreamEncoder(): do not suppress 'no space' errors
......................................................................


Patch Set 3:

(1 comment)

https://gerrit.osmocom.org/c/osmo-pcu/+/17394/3/src/csn1.c 
File src/csn1.c:

https://gerrit.osmocom.org/c/osmo-pcu/+/17394/3/src/csn1.c@1465 
PS3, Line 1465: 
> ... at the start we know we hit an error (negative number of bites) or we simply reached the end, so we are done.

The problem is that we don't know in advance (i.e. without entering the loop) whether it's an error or not. As you have probably seen, some CSN.1 definitions have names like 'M_*_OR_NULL' which means that they're basically optional and can be omitted. The encoder would simply return 0 if pDescr points to an optional field or a ProcessError(...) otherwise.

> This patch doesn't look good to me.

I am now thinking about removing this check from csnStreamDecoder() too.



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

Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-Change-Id: Ie3a15e210624599e39b1e70c8d34efc10c552f6c
Gerrit-Change-Number: 17394
Gerrit-PatchSet: 3
Gerrit-Owner: fixeria <axilirator at gmail.com>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <axilirator at gmail.com>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-Comment-Date: Sat, 07 Mar 2020 08:31:41 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: pespin <pespin at sysmocom.de>
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200307/fbb96766/attachment.htm>


More information about the gerrit-log mailing list