From 7a3aaca1ef4fecf476f9d78b40704fa90f56916f Mon Sep 17 00:00:00 2001 From: Robert Schmidt Date: Thu, 22 Jun 2023 12:18:54 +0200 Subject: [PATCH] Print warning if RFSIMULATOR environment variable is used --- radio/rfsimulator/simulator.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/radio/rfsimulator/simulator.c b/radio/rfsimulator/simulator.c index 4db78e9659..1175d9ec42 100644 --- a/radio/rfsimulator/simulator.c +++ b/radio/rfsimulator/simulator.c @@ -312,6 +312,9 @@ static void rfsimulator_readconfig(rfsimulator_state_t *rfsimulator) { /* for compatibility keep environment variable usage */ if ( getenv("RFSIMULATOR") != NULL ) { rfsimulator->ip=getenv("RFSIMULATOR"); + LOG_W(HW, "The RFSIMULATOR environment variable is deprecated and support will be removed in the future. Instead, add parameter --rfsimulator.serveraddr %s to set the server address. Note: the default is \"server\"; for the gNB/eNB, you don't have to set any configuration.\n", rfsimulator->ip); + LOG_I(HW, "Remove RFSIMULATOR environment variable to get rid of this message and the sleep.\n"); + sleep(10); } if ( strncasecmp(rfsimulator->ip,"enb",3) == 0 ||