diff --git a/executables/nr-uesoftmodem.c b/executables/nr-uesoftmodem.c index 105ffdbbaa..35f8d4dcc2 100644 --- a/executables/nr-uesoftmodem.c +++ b/executables/nr-uesoftmodem.c @@ -458,7 +458,8 @@ int main(int argc, char **argv) #define PACKAGE_VERSION "UNKNOWN-EXPERIMENTAL" #endif // strdup to put the sring in the core file for post mortem identification - LOG_I(HW, "Version: %s\n", strdup(PACKAGE_VERSION)); + char *pckg = strdup(PACKAGE_VERSION); + LOG_I(HW, "Version: %s\n", pckg); PHY_vars_UE_g = malloc(sizeof(*PHY_vars_UE_g) * NB_UE_INST); for (int inst = 0; inst < NB_UE_INST; inst++) { @@ -593,6 +594,7 @@ int main(int argc, char **argv) } } + free(pckg); return 0; }