wbokslag has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-tetra/+/28593 )
Change subject: added brackets; fprintf was erroneously not guarded by if statement ......................................................................
added brackets; fprintf was erroneously not guarded by if statement
Change-Id: I2e8c365ee261bde998a69f0f3531dfe6f3ec49c7 --- M src/tetra_llc.c 1 file changed, 2 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-tetra refs/changes/93/28593/1
diff --git a/src/tetra_llc.c b/src/tetra_llc.c index 045b8df..42ec288 100644 --- a/src/tetra_llc.c +++ b/src/tetra_llc.c @@ -92,9 +92,10 @@ msg->l3h = msg->data; rx_tl_sdu(msg, msgb_l3len(msg));
- if (tun_fd < 0) + if (tun_fd < 0) { tun_fd = tun_alloc("tun0"); fprintf(stderr, "tun_fd=%d\n", tun_fd); + } if (tun_fd >= 0) { uint8_t buf[4096]; int len = osmo_ubit2pbit(buf, msg->l3h+3+4+4+4+4, msgb_l3len(msg)-3-4-4-4-4);