lttng-events: move lttng_transport_find earlier in source file
authorFrancis Deslauriers <francis.deslauriers@efficios.com>
Wed, 5 Feb 2020 18:51:51 +0000 (13:51 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Wed, 18 Nov 2020 18:04:34 +0000 (13:04 -0500)
Will be used by upcoming event notifier code which is earlier in source
file.

Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Change-Id: Idb7be8c682258195166f3b513fee2aa98656de35

src/lttng-events.c

index 2c1e2ae1bb5525e741c496b7c19b0d58d4606b1e..e868525dd039e3ed9250958a45a070e01e48e935 100644 (file)
@@ -108,6 +108,17 @@ void lttng_unlock_sessions(void)
        mutex_unlock(&sessions_mutex);
 }
 
+static struct lttng_transport *lttng_transport_find(const char *name)
+{
+       struct lttng_transport *transport;
+
+       list_for_each_entry(transport, &lttng_transport_list, node) {
+               if (!strcmp(transport->name, name))
+                       return transport;
+       }
+       return NULL;
+}
+
 /*
  * Called with sessions lock held.
  */
@@ -479,17 +490,6 @@ end:
        return ret;
 }
 
-static struct lttng_transport *lttng_transport_find(const char *name)
-{
-       struct lttng_transport *transport;
-
-       list_for_each_entry(transport, &lttng_transport_list, node) {
-               if (!strcmp(transport->name, name))
-                       return transport;
-       }
-       return NULL;
-}
-
 struct lttng_channel *lttng_channel_create(struct lttng_session *session,
                                       const char *transport_name,
                                       void *buf_addr,
This page took 0.028585 seconds and 4 git commands to generate.