Fix: missing context type string in save for ust context
authorJonathan Rajotte Julien <jonathan.r.julien@gmail.com>
Mon, 9 Jun 2014 19:45:39 +0000 (15:45 -0400)
committerDavid Goulet <dgoulet@efficios.com>
Thu, 12 Jun 2014 17:59:07 +0000 (13:59 -0400)
Return string for LTTNG_UST_CONTEXT_PERF_THREAD_COUNTER was missing and
caused an error on save when a context of PERF_THREAD_COUNTER type was
present (Error: Invalid parameter).

Fixes #804

Signed-off-by: Jonathan Rajotte Julien <jonathan.r.julien@gmail.com>
Signed-off-by: David Goulet <dgoulet@efficios.com>
src/bin/lttng-sessiond/save.c
src/common/config/config-session-abi.h
src/common/config/config.c

index 18d303cac9184cbd82ba0671c4b92e75b8eb91e0..8afdbb5002bcb9a7e0bf8ef1d3871ed6e1c7d300 100644 (file)
@@ -258,8 +258,12 @@ const char *get_ust_context_type_string(
        case LTTNG_UST_CONTEXT_PTHREAD_ID:
                context_type_string = config_event_context_pthread_id;
                break;
+       case LTTNG_UST_CONTEXT_PERF_THREAD_COUNTER:
+               context_type_string = config_event_context_perf_thread_counter;
+               break;
        default:
                context_type_string = NULL;
+               break;
        }
 
        return context_type_string;
index 3c51883622c9d960ae0cf75e1755df333219a012..0efd391d5a69ff6c4583ad7784893498620d822b 100644 (file)
@@ -106,5 +106,6 @@ const char * const config_event_context_vppid;
 const char * const config_event_context_pthread_id;
 const char * const config_event_context_hostname;
 const char * const config_event_context_ip;
+const char * const config_event_context_perf_thread_counter;
 
 #endif /* CONFIG_SESSION_INTERNAL_H */
index cdc044d6dc72fda892f9f2d3239140714ad61eb0..4d855bf8a4f8dc0dcbbf3b27ff5e9be663540b93 100644 (file)
@@ -154,6 +154,7 @@ const char * const config_event_context_vppid = "VPPID";
 const char * const config_event_context_pthread_id = "PTHREAD_ID";
 const char * const config_event_context_hostname = "HOSTNAME";
 const char * const config_event_context_ip = "IP";
+const char * const config_event_context_perf_thread_counter = "PERF_THREAD_COUNTER";
 
 struct consumer_output {
        int enabled;
This page took 0.028486 seconds and 4 git commands to generate.