trackers: change error code from "pid" to "id"
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Wed, 4 Jul 2018 20:11:17 +0000 (16:11 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 20 Dec 2019 05:28:06 +0000 (00:28 -0500)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: I0ce03b23350a9f0da9d5f00ac3c6d0e824af9a98
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
include/lttng/lttng-error.h
src/common/error.c

index b3d65ee159fc61c0c627bc4a98260a84d6d016c5..bddd39d7835db0d7534ab5a4ab0ca932fa2449ac 100644 (file)
@@ -134,8 +134,8 @@ enum lttng_error_code {
        LTTNG_ERR_EXCLUSION_NOMEM        = 111, /* Lack of memory while processing event exclusions */
        LTTNG_ERR_INVALID_EVENT_NAME     = 112, /* Invalid event name */
        LTTNG_ERR_INVALID_CHANNEL_NAME   = 113, /* Invalid channel name */
-       LTTNG_ERR_PID_TRACKED            = 114, /* PID already tracked */
-       LTTNG_ERR_PID_NOT_TRACKED        = 115, /* PID not tracked */
+       LTTNG_ERR_ID_TRACKED             = 114, /* ID already tracked */
+       LTTNG_ERR_ID_NOT_TRACKED         = 115, /* ID not tracked */
        LTTNG_ERR_INVALID_CHANNEL_DOMAIN = 116, /* Invalid channel domain */
        LTTNG_ERR_OVERFLOW               = 117, /* Overflow occurred. */
        LTTNG_ERR_SESSION_NOT_STARTED    = 118, /* Session not started */
@@ -180,6 +180,11 @@ enum lttng_error_code {
        LTTNG_ERR_CLEAR_NOT_AVAILABLE_RELAY = 157, /* Clearing a session is not supported by the relay daemon. */
        LTTNG_ERR_CLEAR_FAIL_CONSUMER    = 158, /* Clear failure on consumer */
        LTTNG_ERR_ROTATION_AFTER_STOP_CLEAR = 159, /* Session was already cleared since it became inactive. */
+       LTTNG_ERR_USER_NOT_FOUND         = 160, /* User not found. */
+       LTTNG_ERR_GROUP_NOT_FOUND        = 161, /* Group not found. */
+
+       LTTNG_ERR_PID_TRACKED            = LTTNG_ERR_ID_TRACKED, /* Backward compat alias to LTTNG_ERR_ID_TRACKED */
+       LTTNG_ERR_PID_NOT_TRACKED        = LTTNG_ERR_ID_NOT_TRACKED, /* Backward compat alias to LTTNG_ERR_ID_NOT_TRACKED */
 
        /* MUST be last element */
        LTTNG_ERR_NR,                           /* Last element */
index a95844249a1220496df2f6aff688479102a6f0c8..c5ddadfa07976b2ad406ff3d3819293d3f0f9646 100644 (file)
@@ -179,8 +179,8 @@ static const char *error_string_array[] = {
        [ ERROR_INDEX(LTTNG_ERR_MI_NOT_IMPLEMENTED) ] = "Mi feature not implemented",
        [ ERROR_INDEX(LTTNG_ERR_INVALID_EVENT_NAME) ] = "Invalid event name",
        [ ERROR_INDEX(LTTNG_ERR_INVALID_CHANNEL_NAME) ] = "Invalid channel name",
-       [ ERROR_INDEX(LTTNG_ERR_PID_TRACKED) ] = "PID already tracked",
-       [ ERROR_INDEX(LTTNG_ERR_PID_NOT_TRACKED) ] = "PID not tracked",
+       [ ERROR_INDEX(LTTNG_ERR_ID_TRACKED) ] = "ID already tracked",
+       [ ERROR_INDEX(LTTNG_ERR_ID_NOT_TRACKED) ] = "ID not tracked",
        [ ERROR_INDEX(LTTNG_ERR_INVALID_CHANNEL_DOMAIN) ] = "Invalid channel domain",
        [ ERROR_INDEX(LTTNG_ERR_OVERFLOW) ] = "Overflow occurred",
        [ ERROR_INDEX(LTTNG_ERR_SESSION_NOT_STARTED) ] = "Session not started",
@@ -225,6 +225,8 @@ static const char *error_string_array[] = {
        [ ERROR_INDEX(LTTNG_ERR_CLEAR_NOT_AVAILABLE_RELAY) ] = "Clearing a session is not supported by the relay daemon",
        [ ERROR_INDEX(LTTNG_ERR_CLEAR_FAIL_CONSUMER) ] = "Consumer failed to clear the session",
        [ ERROR_INDEX(LTTNG_ERR_ROTATION_AFTER_STOP_CLEAR) ] = "Session was already cleared since it became inactive",
+       [ ERROR_INDEX(LTTNG_ERR_USER_NOT_FOUND) ] = "User not found",
+       [ ERROR_INDEX(LTTNG_ERR_GROUP_NOT_FOUND) ] = "Group not found",
 
        /* Last element */
        [ ERROR_INDEX(LTTNG_ERR_NR) ] = "Unknown error code"
This page took 0.026745 seconds and 4 git commands to generate.