[lttng-dev] [PATCH lttng-ust] Fix: get tid not pid in vtid context

Mathieu Desnoyers mathieu.desnoyers at efficios.com
Mon Jun 3 14:52:38 EDT 2019


Merged into master (only applies to master).

Thanks!

Mathieu

----- On Jun 3, 2019, at 2:21 PM, Michael Jeanson mjeanson at efficios.com wrote:

> Looks like an over enthusiastic copy/paste error in
> commit 98357ffd0125c23387d42d4b706c56077392326d.
> 
> Signed-off-by: Michael Jeanson <mjeanson at efficios.com>
> ---
> liblttng-ust/lttng-context-vtid.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/liblttng-ust/lttng-context-vtid.c
> b/liblttng-ust/lttng-context-vtid.c
> index 5cefe953..80661f63 100644
> --- a/liblttng-ust/lttng-context-vtid.c
> +++ b/liblttng-ust/lttng-context-vtid.c
> @@ -63,7 +63,7 @@ pid_t wrapper_getvtid(void)
> 
> 	vtid = CMM_LOAD_SHARED(URCU_TLS(cached_vtid));
> 	if (caa_unlikely(!vtid)) {
> -		vtid = getpid();
> +		vtid = gettid();
> 		CMM_STORE_SHARED(URCU_TLS(cached_vtid), vtid);
> 	}
> 	return vtid;
> --
> 2.17.1

-- 
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com


More information about the lttng-dev mailing list