Skip to content

Commit e97e1cf

Browse files
steadmongitster
authored andcommitted
trace2: add a public function for getting the SID
Add a public wrapper, trace2_session_id(), around tr2_sid_get(), which is intended to be private trace2 implementation. Signed-off-by: Josh Steadmon <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 81bd549 commit e97e1cf

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

trace2.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -792,3 +792,8 @@ void trace2_printf(const char *fmt, ...)
792792
va_end(ap);
793793
}
794794
#endif
795+
796+
const char *trace2_session_id(void)
797+
{
798+
return tr2_sid_get();
799+
}

trace2.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -500,4 +500,6 @@ void trace2_collect_process_info(enum trace2_process_info_reason reason);
500500
} while (0)
501501
#endif
502502

503+
const char *trace2_session_id(void);
504+
503505
#endif /* TRACE2_H */

0 commit comments

Comments
 (0)