From 3ecb2bb60472ea291a5f13b4babe6fd9a7fba028 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Thu, 21 Aug 2014 16:12:50 +0200 Subject: sysmobts: Initialize fd with an invalid fd Initialize the ucinfo with an invalid fd to prevent writing on fd=0 by accident. --- src/osmo-bts-sysmo/misc/sysmobts_mgr_2050.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/osmo-bts-sysmo/misc') diff --git a/src/osmo-bts-sysmo/misc/sysmobts_mgr_2050.c b/src/osmo-bts-sysmo/misc/sysmobts_mgr_2050.c index e3cd104b..e5a2c800 100644 --- a/src/osmo-bts-sysmo/misc/sysmobts_mgr_2050.c +++ b/src/osmo-bts-sysmo/misc/sysmobts_mgr_2050.c @@ -51,7 +51,8 @@ struct ucinfo { static struct uc ucontrol0 = { .id = 0, - .path = "/dev/ttyS0" + .path = "/dev/ttyS0", + .fd = -1, }; /********************************************************************** -- cgit v1.2.3