OBS-URL: https://build.opensuse.org/package/show/network:telephony/libosmo-abis?expand=0&rev=2
41 lines
1.3 KiB
Diff
41 lines
1.3 KiB
Diff
From 5731dd74f76e7b9c6778ee57937fc92bb8be34d3 Mon Sep 17 00:00:00 2001
|
|
From: Holger Hans Peter Freyther <zecke@selfish.org>
|
|
Date: Sat, 9 Mar 2013 17:35:17 +0100
|
|
Subject: [PATCH 2/2] misdn: Set ret to 0 when using the LAPD from userspace
|
|
|
|
Warning:
|
|
input/misdn.c:252:6: warning: variable 'ret' is used uninitialized whenever 'if' condition is
|
|
true [-Wsometimes-uninitialized]
|
|
if (mline->use_userspace_lapd) {
|
|
^~~~~~~~~~~~~~~~~~~~~~~~~
|
|
input/misdn.c:289:9: note: uninitialized use occurs here
|
|
return ret;
|
|
^~~
|
|
input/misdn.c:252:2: note: remove the 'if' if its condition is always false
|
|
if (mline->use_userspace_lapd) {
|
|
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
input/misdn.c:241:9: note: initialize the variable 'ret' to silence this warning
|
|
int ret;
|
|
^
|
|
= 0
|
|
1 warning generated.
|
|
---
|
|
src/input/misdn.c | 1 +
|
|
1 file changed, 1 insertion(+)
|
|
|
|
diff --git a/src/input/misdn.c b/src/input/misdn.c
|
|
index 5fdd847..a72a21e 100644
|
|
--- a/src/input/misdn.c
|
|
+++ b/src/input/misdn.c
|
|
@@ -255,6 +255,7 @@ static int handle_ts1_write(struct osmo_fd *bfd)
|
|
osmo_hexdump(msg->data, msg->len));
|
|
lapd_transmit(e1i_ts->lapd, sign_link->tei,
|
|
sign_link->sapi, msg);
|
|
+ ret = 0;
|
|
} else {
|
|
l2_data = msg->data;
|
|
|
|
--
|
|
1.8.2
|
|
|