[PATCH] teip is a pointer, not an int

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/.

Alexander Huemer alexander.huemer at xx.vu
Fri Nov 6 19:57:23 UTC 2015


---
 examples/lapd-over-datagram-network.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/examples/lapd-over-datagram-network.c b/examples/lapd-over-datagram-network.c
index 74bba74..8d3fbde 100644
--- a/examples/lapd-over-datagram-network.c
+++ b/examples/lapd-over-datagram-network.c
@@ -129,7 +129,7 @@ void lapd_rx_cb(struct osmo_dlsap_prim *dp, uint8_t tei, uint8_t sapi,
 
 int main(int argc, char *argv[])
 {
-	int teip;
+	struct lapd_tei *teip;
 
 	tall_test = talloc_named_const(NULL, 1, "lapd_test");
 
@@ -159,7 +159,7 @@ int main(int argc, char *argv[])
 	}
 
 	teip = lapd_tei_alloc(lapd, tei);
-	if (teip == 0) {
+	if (teip == NULL) {
 		LOGP(DLAPDTEST, LOGL_ERROR, "cannot assign TEI\n");
 		exit(EXIT_FAILURE);
 	}
-- 
2.6.2




More information about the OpenBSC mailing list