Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
close(sock);
return -EINVAL;
}
+ if (msg->major != LTTNG_UST_COMM_MAJOR) {
+ ERR("Registration failed: application \"%s\" (pid: %d) has "
+ "communication protocol version %u.%u, but sessiond supports 2.x.\n",
+ msg->name, msg->pid, msg->major, msg->minor);
+ close(sock);
+ return -EINVAL;
+ }
lta = zmalloc(sizeof(struct ust_app));
if (lta == NULL) {
PERROR("malloc");
#include "trace-ust.h"
/* lttng-ust supported version. */
-#define UST_APP_MAJOR_VERSION 1
+#define LTTNG_UST_COMM_MAJOR 2 /* comm protocol major version */
+#define UST_APP_MAJOR_VERSION 2 /* UST version supported */
#define UST_APP_EVENT_LIST_SIZE 32