mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-10-02 08:42:32 +00:00
gstinfo: Add an explicit enum for GST_STACK_TRACE_SHOW_NONE
The code implicitly uses this value when the stack trace is not FULL. Mostly useful for documenting the behaviour when each flag is passed and for translating to/from strings.
This commit is contained in:
parent
6412988975
commit
145f8546c4
3 changed files with 10 additions and 5 deletions
|
@ -2885,8 +2885,8 @@ done:
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* gst_debug_get_stack_trace:
|
* gst_debug_get_stack_trace:
|
||||||
* @flags: A set of #GstStackTraceFlags to determine how the stack
|
* @flags: A set of #GstStackTraceFlags to determine how the stack trace should
|
||||||
* trace should look like. Pass 0 to retrieve a minimal backtrace.
|
* look like. Pass #GST_STACK_TRACE_SHOW_NONE to retrieve a minimal backtrace.
|
||||||
*
|
*
|
||||||
* Returns: (nullable): a stack trace, if libunwind or glibc backtrace are
|
* Returns: (nullable): a stack trace, if libunwind or glibc backtrace are
|
||||||
* present, else %NULL.
|
* present, else %NULL.
|
||||||
|
|
|
@ -177,12 +177,17 @@ typedef enum { /*< flags >*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* GstStackTraceFlags:
|
* GstStackTraceFlags:
|
||||||
* @GST_STACK_TRACE_SHOW_FULL: Try to retrieve as much information as
|
* @GST_STACK_TRACE_SHOW_NONE: Try to retrieve the minimum information
|
||||||
* possible when getting the stack trace
|
* available, which may be none on some platforms
|
||||||
|
* (Since: 1.18)
|
||||||
|
* @GST_STACK_TRACE_SHOW_FULL: Try to retrieve as much information as possible,
|
||||||
|
* including source information when getting the
|
||||||
|
* stack trace
|
||||||
*
|
*
|
||||||
* Since: 1.12
|
* Since: 1.12
|
||||||
*/
|
*/
|
||||||
typedef enum {
|
typedef enum {
|
||||||
|
GST_STACK_TRACE_SHOW_NONE = 0,
|
||||||
GST_STACK_TRACE_SHOW_FULL = 1 << 0
|
GST_STACK_TRACE_SHOW_FULL = 1 << 0
|
||||||
} GstStackTraceFlags;
|
} GstStackTraceFlags;
|
||||||
|
|
||||||
|
|
|
@ -106,7 +106,7 @@ set_print_stack_trace_from_string (GstLeaksTracer * self, const gchar * str)
|
||||||
if (g_strcmp0 (str, "full") == 0)
|
if (g_strcmp0 (str, "full") == 0)
|
||||||
self->trace_flags = GST_STACK_TRACE_SHOW_FULL;
|
self->trace_flags = GST_STACK_TRACE_SHOW_FULL;
|
||||||
else
|
else
|
||||||
self->trace_flags = 0;
|
self->trace_flags = GST_STACK_TRACE_SHOW_NONE;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in a new issue