daniel has posted comments on this change. ( https://gerrit.osmocom.org/12954 )

Change subject: Rewrite Packet Downlink Assignment
......................................................................


Patch Set 6:

(1 comment)

https://gerrit.osmocom.org/#/c/12954/6/src/encoding.cpp
File src/encoding.cpp:

https://gerrit.osmocom.org/#/c/12954/6/src/encoding.cpp@104
PS6, Line 104: static inline bool write_tai(bitvec *dest, unsigned& wp, int8_t 
tai)
It's a bit weird that we now have two functions that essentially do the same. 
Could we wrap one in the other?

Something like this looks equivalent for write_tai, but needs knowledge of 
bitvec internals:

dest->cur_bit = wp;
write_ta_index(dest, tai);
wp = dest->cur_bit;

if (tai < 0)
 return false;
else
 return true;

I must admit that I don't understand the idea behind wp since it is that same 
value as dest->cur_bit (unless I'm missing something). Maybe what's missing is 
a bitvec function to set and get the current bit cursor position?



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

Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie180733d2584ebb16fb80b84526d0dbc70e3d441
Gerrit-Change-Number: 12954
Gerrit-PatchSet: 6
Gerrit-Owner: Max <[email protected]>
Gerrit-Reviewer: Harald Welte <[email protected]>
Gerrit-Reviewer: Jenkins Builder (1000002)
Gerrit-Reviewer: Max <[email protected]>
Gerrit-Reviewer: Neels Hofmeyr <[email protected]>
Gerrit-Reviewer: Pau Espin Pedrol <[email protected]>
Gerrit-Reviewer: osmith <[email protected]>
Gerrit-Reviewer: tnt <[email protected]>
Gerrit-CC: Vadim Yanitskiy <[email protected]>
Gerrit-CC: daniel <[email protected]>
Gerrit-Comment-Date: Fri, 22 Feb 2019 16:42:44 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No

Reply via email to