diff options
-rw-r--r-- | src/journald/instutil.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/journald/instutil.c b/src/journald/instutil.c index 12f63bf..b3987bc 100644 --- a/src/journald/instutil.c +++ b/src/journald/instutil.c @@ -204,7 +204,6 @@ int create_LMI_JournalLogRecord(sd_journal *j, if (r >= 0 && d != NULL && strlen(d) > 0) { char *conv_err = NULL; long int i = strtol(d, &conv_err, 10); - g_free(d); if (conv_err == NULL || *conv_err == '\0') switch (i) { case LOG_EMERG: @@ -235,6 +234,7 @@ int create_LMI_JournalLogRecord(sd_journal *j, LMI_JournalLogRecord_Set_PerceivedSeverity_Information(rec); break; } + g_free(d); } return 1; |