ABI: refuse non-matching ABI minor version on event registration stable-2.8
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Mon, 6 Nov 2017 21:10:44 +0000 (16:10 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 6 Nov 2017 21:36:17 +0000 (16:36 -0500)
commit97001ca3c66bf902ac0f2a54367252b670ea789a
tree53756c8d47cc6fc3a7391091f0d0b758c9efdafd
parentdb4a4c8735164155d64c87b80e6bee0f284fa652
ABI: refuse non-matching ABI minor version on event registration

In scenarios where a lttng-tools 2.8 (lttng-ust 2.8) stack is running
and an application linked against a lttng-ust 2.7, event registration
will fail on fields size validation [1]. This is not expected based on
the ABI versioning exposed by lttng-ust 2.7 (6.0) and lttng-ust 2.8
(6.1).

The same happen if the scenario is reversed.

This is the result of a change in _ustctl_basic_type.

2.8 introduced enumeration to _ustctl_basic_type. The defined padding is
of 296 while the new union member is 312 (310 of real data + 2 for
alignment) pushing the structure size to 312 instead of the previous
296. This should have been an major ABI break but until now the problem
did not surface.

To prevent this, refuse non matching minor version. No need to check for
particular major,minor version since only 6.0 (ust 2.7) and 6.1 (ust
2.8) exist until a major ABI break.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
liblttng-ust-ctl/ustctl.c
This page took 0.025848 seconds and 4 git commands to generate.