Add lttng-error.h containing every API err. code
authorDavid Goulet <dgoulet@efficios.com>
Wed, 22 Aug 2012 19:04:52 +0000 (15:04 -0400)
committerDavid Goulet <dgoulet@efficios.com>
Fri, 24 Aug 2012 16:17:16 +0000 (12:17 -0400)
commitf73fabfda365d22e7dd180fb1614e37c446fbd9e
treec730ee7b7934619de4e5c3307488b1ac2be36ac0
parent54773d681e44cb32d6923bd2db0dcecd4bd10079
Add lttng-error.h containing every API err. code

Move all error codes from sessiond-comm.h to lttng-error.h and rename
them changing the prefix LTTCOMM* to the LTTNG_ERR_*.

With this change, the error codes will soon be public in
<lttng/lttng-error.h> that lttng.h will include by default.

This commit also removes a bunch of unused code but does NOT changed the
values so we don't break the 2.0 API.

The lttng_strerror() call uses the new error_get_str function. The
lttcomm_* API now only have internal communication error code such as
the consumerd errors. Those codes must NEVER be exposed to the public
API or, in that case, must be moved to lttng-error.h *without* changing
the current values of the lttng_error_code enum.

The gaps in the lttng_error_code enum found in lttng-error.h can be used
for new error codes but the assigned value are considered immutable for
the 2.x API.

Signed-off-by: David Goulet <dgoulet@efficios.com>
33 files changed:
include/lttng/lttng-error.h [new file with mode: 0644]
src/bin/lttng-consumerd/lttng-consumerd.c
src/bin/lttng-relayd/main.c
src/bin/lttng-sessiond/channel.c
src/bin/lttng-sessiond/cmd.c
src/bin/lttng-sessiond/consumer.c
src/bin/lttng-sessiond/context.c
src/bin/lttng-sessiond/event.c
src/bin/lttng-sessiond/filter.c
src/bin/lttng-sessiond/kernel-consumer.c
src/bin/lttng-sessiond/kernel.c
src/bin/lttng-sessiond/main.c
src/bin/lttng-sessiond/session.c
src/bin/lttng-sessiond/ust-app.c
src/bin/lttng/commands/create.c
src/bin/lttng/commands/destroy.c
src/bin/lttng/commands/enable_channels.c
src/bin/lttng/commands/enable_consumer.c
src/bin/lttng/commands/enable_events.c
src/bin/lttng/commands/start.c
src/bin/lttng/commands/stop.c
src/common/Makefile.am
src/common/consumer.c
src/common/error.c [new file with mode: 0644]
src/common/error.h
src/common/kernel-consumer/kernel-consumer.c
src/common/relayd/relayd.c
src/common/sessiond-comm/sessiond-comm.c
src/common/sessiond-comm/sessiond-comm.h
src/common/ust-consumer/ust-consumer.c
src/lib/lttng-ctl/lttng-ctl.c
tests/tools/Makefile.am
tests/tools/test_sessions.c
This page took 0.029231 seconds and 4 git commands to generate.