[PATCH] input/ipaccess: Fix segv caused by use of uninitialized var

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/OpenBSC@lists.osmocom.org/.

Sylvain Munaut 246tnt at gmail.com
Wed Sep 30 20:35:04 UTC 2009


From: Sylvain Munaut <tnt at 246tNt.com>

This is a regression coming from the recent split of the
handle_ts1_read method in two.

Signed-off-by: Sylvain Munaut <tnt at 246tNt.com>
---
 openbsc/src/input/ipaccess.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/openbsc/src/input/ipaccess.c b/openbsc/src/input/ipaccess.c
index 8a22810..40891ae 100644
--- a/openbsc/src/input/ipaccess.c
+++ b/openbsc/src/input/ipaccess.c
@@ -319,7 +319,7 @@ static int handle_ts1_read(struct bsc_fd *bfd)
 		return error;
 	}
 
-	DEBUGP(DMI, "RX %u: %s\n", ts_nr, hexdump(msgb_l2(msg), ret));
+	DEBUGP(DMI, "RX %u: %s\n", ts_nr, hexdump(msgb_l2(msg), msgb_l2len(msg)));
 
 	hh = (struct ipaccess_head *) msg->data;
 	if (hh->proto == IPAC_PROTO_IPACCESS) {
-- 
1.6.4





More information about the OpenBSC mailing list