pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-gprs/+/31810 ) Change subject: sndcp: Avoid propagating rc=1 ...................................................................... sndcp: Avoid propagating rc=1 Those functions guarantee to the caller that the prim is always freed, and hence returning 1 has not meaning there. Fix similar to bab234c2ea13b1ffa81bdb2c19a5864746b21390 in rlcmac layer. Change-Id: If3c9287d839198dc079993c4d32780fb1c2bc6fd --- M src/sndcp/sndcp_prim.c 1 file changed, 18 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/libosmo-gprs refs/changes/10/31810/1 diff --git a/src/sndcp/sndcp_prim.c b/src/sndcp/sndcp_prim.c index 63591d7..dee7dbe 100644 --- a/src/sndcp/sndcp_prim.c +++ b/src/sndcp/sndcp_prim.c @@ -533,6 +533,8 @@ /* Special return value '1' means: do not free */ if (rc != 1) msgb_free(msg); + else + rc = 0; return rc; } @@ -676,5 +678,7 @@ /* Special return value '1' means: do not free */ if (rc != 1) msgb_free(msg); + else + rc = 0; return rc; } -- To view, visit https://gerrit.osmocom.org/c/libosmo-gprs/+/31810 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmo-gprs Gerrit-Branch: master Gerrit-Change-Id: If3c9287d839198dc079993c4d32780fb1c2bc6fd Gerrit-Change-Number: 31810 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin@sysmocom.de> Gerrit-MessageType: newchange