[lttng-dev] [PATCH lttng-tools 3/5] Cleanup: remove unused internal lttng_session_descriptor_get_base_path

Jonathan Rajotte jonathan.rajotte-julien at efficios.com
Fri Oct 25 18:12:02 EDT 2019


Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien at efficios.com>
---

Feel free to squash this into the previous commits.

---
 include/lttng/session-descriptor-internal.h |  4 ----
 src/common/session-descriptor.c             | 23 ---------------------
 2 files changed, 27 deletions(-)

diff --git a/include/lttng/session-descriptor-internal.h b/include/lttng/session-descriptor-internal.h
index 18a70bad4..09d493393 100644
--- a/include/lttng/session-descriptor-internal.h
+++ b/include/lttng/session-descriptor-internal.h
@@ -109,8 +109,4 @@ int lttng_session_descriptor_assign(
 		struct lttng_session_descriptor *dst_descriptor,
 		const struct lttng_session_descriptor *src_descriptor);
 
-LTTNG_HIDDEN
-int lttng_session_descriptor_get_base_path(struct lttng_session_descriptor *dst,
-		const char **base_path);
-
 #endif /* LTTNG_SESSION_DESCRIPTOR_INTERNAL_H */
diff --git a/src/common/session-descriptor.c b/src/common/session-descriptor.c
index 6dea5ee7c..224138dd2 100644
--- a/src/common/session-descriptor.c
+++ b/src/common/session-descriptor.c
@@ -1176,26 +1176,3 @@ int lttng_session_descriptor_assign(
 end:
 	return ret;
 }
-
-LTTNG_HIDDEN
-int lttng_session_descriptor_get_base_path(struct lttng_session_descriptor *dst,
-		const char **_base_path)
-{
-	switch (dst->output_type) {
-	case LTTNG_SESSION_DESCRIPTOR_OUTPUT_TYPE_NETWORK:
-	{
-		if (dst->output.network.control &&
-				dst->output.network.control->subdir[0]) {
-			*_base_path = dst->output.network.control->subdir;
-		} else {
-			*_base_path = NULL;
-		}
-		break;
-	}
-	case LTTNG_SESSION_DESCRIPTOR_OUTPUT_TYPE_LOCAL:
-	case LTTNG_SESSION_DESCRIPTOR_OUTPUT_TYPE_NONE:
-		*_base_path = NULL;
-		break;
-	}
-	return 0;
-}
-- 
2.17.1



More information about the lttng-dev mailing list