pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/libosmocore/+/19067 )

Change subject: Revert "gsmtap_makemsg_ex: NULL for unknown chan_type"
......................................................................

Revert "gsmtap_makemsg_ex: NULL for unknown chan_type"

Reverting due to being completely normal for some applications to submit
usning this channel type when decoding/parsing failed and hence not
being able to determine channel type.

This reverts Change-Id Ib4147a33a75c3cf425c30da8b0678c7fba8a371d
(commit 12f93be6073ed89055862baafbfe0e08e50ed17a.)

Change-Id: I6ebaa89cc3422df1d7fd2365a6176cb2902d1c67
---
M src/gsmtap_util.c
1 file changed, 1 insertion(+), 5 deletions(-)

Approvals:
  laforge: Looks good to me, but someone else must approve
  pespin: Looks good to me, approved
  Hoernchen: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/src/gsmtap_util.c b/src/gsmtap_util.c
index 8674f1c..9a0ac02 100644
--- a/src/gsmtap_util.c
+++ b/src/gsmtap_util.c
@@ -169,8 +169,7 @@
  *  \param[in] snr Signal/Noise Ratio (SNR)
  *  \param[in] data Pointer to data buffer
  *  \param[in] len Length of \ref data
- *  \return dynamically allocated message buffer containing data,
- *          or NULL for unknown chan_type
+ *  \return dynamically allocated message buffer containing data
  *
  * This function will allocate a new msgb and fill it with a GSMTAP
  * header containing the information
@@ -183,9 +182,6 @@
        struct gsmtap_hdr *gh;
        uint8_t *dst;

-       if (chan_type == GSMTAP_CHANNEL_UNKNOWN)
-               return NULL;
-
        msg = msgb_alloc(sizeof(*gh) + len, "gsmtap_tx");
        if (!msg)
                return NULL;

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

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I6ebaa89cc3422df1d7fd2365a6176cb2902d1c67
Gerrit-Change-Number: 19067
Gerrit-PatchSet: 3
Gerrit-Owner: pespin <pes...@sysmocom.de>
Gerrit-Reviewer: Hoernchen <ew...@sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillm...@sysmocom.de>
Gerrit-Reviewer: laforge <lafo...@osmocom.org>
Gerrit-Reviewer: pespin <pes...@sysmocom.de>
Gerrit-CC: neels <nhofm...@sysmocom.de>
Gerrit-MessageType: merged

Reply via email to