new codename, reset version to git
[paraslash.git] / audiod_command.c
index 349480ff1f34f5a9bfebe57f26ddad6f0aef93ce..77a0a1ee32bb7a1b3241afc549d999f124a6073e 100644 (file)
@@ -350,7 +350,7 @@ err_out:
        return 1;
 }
 
-int __noreturn com_term(int fd, __a_unused int argc, __a_unused char **argv)
+__noreturn int com_term(int fd, __a_unused int argc, __a_unused char **argv)
 {
        close(fd);
        clean_exit(EXIT_SUCCESS, "terminating on user request");
@@ -477,7 +477,9 @@ out:
        }
        return ret;
 }
-
+/**
+ * send the current audiod status to all connected stat clients
+ */
 void audiod_status_dump(void)
 {
        struct timeval *t = wstime();
@@ -518,6 +520,7 @@ void audiod_status_dump(void)
        old = stat_task->stat_item_values[SI_DECODER_FLAGS];
        new = decoder_flags();
        if (!old || strcmp(old, new)) {
+               free(old);
                stat_client_write(new, SI_DECODER_FLAGS);
                stat_task->stat_item_values[SI_DECODER_FLAGS] = new;
        } else