pespin has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/28103 )
Change subject: osmo-arfcn: Fix false positive in gcc 12.1.0 ......................................................................
osmo-arfcn: Fix false positive in gcc 12.1.0
The pointer is initialized in all its uses, however newer gcc warns about it: """ inlined from ‘main’ at /libosmocore/utils/osmo-arfcn.c:144:16: /usr/include/bits/stdlib-float.h:27:10: error: ‘param’ may be used uninitialized [-Werror=maybe-uninitialized] """
Change-Id: If3eff4ab14a7b2a950386244c9b5f2b9adb32f99 --- M utils/osmo-arfcn.c 1 file changed, 1 insertion(+), 1 deletion(-)
Approvals: Jenkins Builder: Verified fixeria: Looks good to me, approved
diff --git a/utils/osmo-arfcn.c b/utils/osmo-arfcn.c index 9e4534f..3d4fb50 100644 --- a/utils/osmo-arfcn.c +++ b/utils/osmo-arfcn.c @@ -93,7 +93,7 @@ { int arfcn, freq, pcs = 0, uplink = -1; int opt; - char *param; + char *param = NULL; enum program_mode mode = MODE_NONE;
while ((opt = getopt(argc, argv, "pa:f:udh")) != -1) {