- if (llm != NULL) {
- ret = lttcomm_send_unix_sock(sock, llm,
- sizeof(struct lttcomm_lttng_msg));
- free(llm);
- if (ret < 0) {
- continue;
- }
- } else {
- /* The lttcomm_lttng_msg struct was not allocated
- * correctly. Fatal error since the daemon is not able
- * to respond. However, we still permit client connection.
- *
- * TODO: We should have a default llm that tells the client
- * that the sessiond had a fatal error and thus the client could
- * take action to restart ltt-sessiond or inform someone.
- */
+ ret = process_client_msg(sock, &lsm);
+ if (ret < 0) {
+ /* Error detected but still accept command */
+ continue;