/** The list of all status items used by para_{server,audiod,gui}. */
const char *status_item_list[] = {STATUS_ITEMS};
-/**
- * Add a status client to the list.
- *
- * \param fd The file descriptor of the client.
- * \param mask Bitfield of status items for this client.
- * \param parser_friendly Enable parser-friendly output mode.
- *
- * Only those status items having the bit set in \a mask will be
- * sent to the client.
+/*
+ * Add a status client to the global client list and increment num_clients.
*
- * \return Positive value on success, or -E_TOO_MANY_CLIENTS if
- * the number of connected clients exceeds #MAX_STAT_CLIENTS.
+ * The mask parameter specifies which status items are sent to the client.
*/
-static int stat_client_add(int fd, uint64_t mask, int parser_friendly)
+static int stat_client_add(int fd, uint64_t mask, bool parser_friendly)
{
struct stat_client *new_client;
int ret;
static int com_stat(int fd, struct lls_parse_result *lpr)
{
- int i, ret, parser_friendly = 0;
+ int i, ret;
+ bool parser_friendly = false;
uint64_t mask = 0;
const uint64_t one = 1;
struct para_buffer b = {.flags = 0};
return ret;
r = lls_opt_result(LSG_AUDIOD_CMD_STAT_OPT_PARSER_FRIENDLY, lpr);
if (lls_opt_given(r) > 0) {
- parser_friendly = 1;
+ parser_friendly = true;
b.flags = PBF_SIZE_PREFIX;
}
num_inputs = lls_num_inputs(lpr);