lynxis lazus has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/libosmo-sigtran/+/42823?usp=email )


Change subject: m3ua: fix missing decoding of message priority & network 
indicator flag
......................................................................

m3ua: fix missing decoding of message priority & network indicator flag

The missing parenthesis always or'ed with a 0x0 into the sio field because
of operator precendence. Left shift is stronger than a binary and.

Change-Id: I7a07363646f66c5c672a2c0d261ca33356b43031
---
M src/m3ua.c
1 file changed, 2 insertions(+), 2 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmo-sigtran 
refs/changes/23/42823/1

diff --git a/src/m3ua.c b/src/m3ua.c
index 243f5b9..583800b 100644
--- a/src/m3ua.c
+++ b/src/m3ua.c
@@ -324,8 +324,8 @@
        param->sls = mdh->sls;
        /* re-construct SIO */
        param->sio = (mdh->si & 0xF) |
-                    (mdh->mp & 0x3 << 4) |
-                    (mdh->ni & 0x3 << 6);
+                    ((mdh->mp & 0x3) << 4) |
+                    ((mdh->ni & 0x3) << 6);
 }

 struct msgb *m3ua_msgb_alloc(const char *name)

--
To view, visit https://gerrit.osmocom.org/c/libosmo-sigtran/+/42823?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings?usp=email

Gerrit-MessageType: newchange
Gerrit-Project: libosmo-sigtran
Gerrit-Branch: master
Gerrit-Change-Id: I7a07363646f66c5c672a2c0d261ca33356b43031
Gerrit-Change-Number: 42823
Gerrit-PatchSet: 1
Gerrit-Owner: lynxis lazus <[email protected]>

Reply via email to