mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-10-01 11:26:37 +02:00
systemtap: Use correct formatters/types
Try to avoid casting variables to potentially smaller types to fit defined probes. This can truncate values and lead to wrong results. Also make sure that signedness matches. Since GType can be even 128 bit on CHERI architecture, cast all these various types used based on platform to uintmax_t which SystemTap properly processes.
This commit is contained in:
@@ -79,7 +79,7 @@ probe gio.task_propagate = process("@ABS_GLIB_RUNTIME_LIBDIR@/libgio-2.0.so.0.@L
|
|||||||
{
|
{
|
||||||
task = $arg1;
|
task = $arg1;
|
||||||
error_set = $arg2;
|
error_set = $arg2;
|
||||||
probestr = sprintf("gio.task_propagate(%p) -> %u", task, error_set);
|
probestr = sprintf("gio.task_propagate(%p) -> %d", task, error_set);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -103,5 +103,5 @@ probe gio.task_after_run_in_thread = process("@ABS_GLIB_RUNTIME_LIBDIR@/libgio-2
|
|||||||
{
|
{
|
||||||
task = $arg1;
|
task = $arg1;
|
||||||
thread_cancelled = $arg2;
|
thread_cancelled = $arg2;
|
||||||
probestr = sprintf("gio.task_after_run_in_thread(%p) -> %u", task, thread_cancelled);
|
probestr = sprintf("gio.task_after_run_in_thread(%p) -> %d", task, thread_cancelled);
|
||||||
}
|
}
|
||||||
|
@@ -4,7 +4,7 @@ provider gio {
|
|||||||
probe task__set_priority(void*, int);
|
probe task__set_priority(void*, int);
|
||||||
probe task__set_source_tag(void*, void*);
|
probe task__set_source_tag(void*, void*);
|
||||||
probe task__before_return(void*, void*, void*, void*);
|
probe task__before_return(void*, void*, void*, void*);
|
||||||
probe task__propagate(void*, unsigned int);
|
probe task__propagate(void*, int);
|
||||||
probe task__before_run_in_thread(void*, void*);
|
probe task__before_run_in_thread(void*, void*);
|
||||||
probe task__after_run_in_thread(void*, unsigned int);
|
probe task__after_run_in_thread(void*, int);
|
||||||
};
|
};
|
||||||
|
@@ -16,7 +16,7 @@ probe glib.quark_new = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_C
|
|||||||
{
|
{
|
||||||
str = user_string ($arg1);
|
str = user_string ($arg1);
|
||||||
quark = $arg2;
|
quark = $arg2;
|
||||||
probestr = sprintf("glib.quark_new(%s) -> %d", str, quark);
|
probestr = sprintf("glib.quark_new(%s) -> %u", str, quark);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -32,7 +32,7 @@ probe glib.mem_alloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_C
|
|||||||
n_bytes = $arg2;
|
n_bytes = $arg2;
|
||||||
zeroed = $arg3;
|
zeroed = $arg3;
|
||||||
failable = $arg4;
|
failable = $arg4;
|
||||||
probestr = sprintf("glib.mem_alloc(n_bytes=%d) -> %p", n_bytes, mem);
|
probestr = sprintf("glib.mem_alloc(n_bytes=%u) -> %p", n_bytes, mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -57,7 +57,7 @@ probe glib.mem_realloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT
|
|||||||
old_mem = $arg2;
|
old_mem = $arg2;
|
||||||
n_bytes = $arg3;
|
n_bytes = $arg3;
|
||||||
failable = $arg4;
|
failable = $arg4;
|
||||||
probestr = sprintf("glib.mem_realloc(old_mem=%p, n_bytes=%d) -> %p", old_mem, n_bytes, mem);
|
probestr = sprintf("glib.mem_realloc(old_mem=%p, n_bytes=%u) -> %p", old_mem, n_bytes, mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -69,7 +69,7 @@ probe glib.slice_alloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT
|
|||||||
{
|
{
|
||||||
mem = $arg1;
|
mem = $arg1;
|
||||||
n_bytes = $arg2;
|
n_bytes = $arg2;
|
||||||
probestr = sprintf("glib.slice_alloc(n_bytes=%d) -> %p", n_bytes, mem);
|
probestr = sprintf("glib.slice_alloc(n_bytes=%u) -> %p", n_bytes, mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -81,7 +81,7 @@ probe glib.slice_free = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_
|
|||||||
{
|
{
|
||||||
mem = $arg1;
|
mem = $arg1;
|
||||||
n_bytes = $arg2;
|
n_bytes = $arg2;
|
||||||
probestr = sprintf("glib.slice_free(n_bytes=%d) -> %p", n_bytes, mem);
|
probestr = sprintf("glib.slice_free(n_bytes=%u) -> %p", n_bytes, mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -95,7 +95,7 @@ probe glib.main_after_prepare = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.s
|
|||||||
source = $arg1;
|
source = $arg1;
|
||||||
prepare = $arg2;
|
prepare = $arg2;
|
||||||
source_timeout = $arg3;
|
source_timeout = $arg3;
|
||||||
probestr = sprintf("glib.main_after_prepare(source=%p, prepare=%p) -> %u", source, prepare, source_timeout);
|
probestr = sprintf("glib.main_after_prepare(source=%p, prepare=%p) -> %d", source, prepare, source_timeout);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -109,7 +109,7 @@ probe glib.main_after_check = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.
|
|||||||
source = $arg1;
|
source = $arg1;
|
||||||
check = $arg2;
|
check = $arg2;
|
||||||
result = $arg3;
|
result = $arg3;
|
||||||
probestr = sprintf("glib.main_after_check(source=%p, check=%p) -> %u", source, check, result);
|
probestr = sprintf("glib.main_after_check(source=%p, check=%p) -> %d", source, check, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -143,7 +143,7 @@ probe glib.main_after_dispatch = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.
|
|||||||
source_ptr = $arg2;
|
source_ptr = $arg2;
|
||||||
dispatch = $arg3;
|
dispatch = $arg3;
|
||||||
need_destroy = $arg4;
|
need_destroy = $arg4;
|
||||||
probestr = sprintf("glib.main_after_dispatch(source=%s(%p), dispatch=%p) -> %u", source, source_ptr, dispatch, need_destroy);
|
probestr = sprintf("glib.main_after_dispatch(source=%s(%p), dispatch=%p) -> %d", source, source_ptr, dispatch, need_destroy);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -205,7 +205,7 @@ probe glib.main_context_acquire = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0
|
|||||||
{
|
{
|
||||||
context = $arg1;
|
context = $arg1;
|
||||||
success = $arg2;
|
success = $arg2;
|
||||||
probestr = sprintf("glib.main_context_acquire(context=%p) -> %u", context, success);
|
probestr = sprintf("glib.main_context_acquire(context=%p) -> %d", context, success);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -269,7 +269,7 @@ probe glib.main_context_after_prepare = process("@ABS_GLIB_RUNTIME_LIBDIR@/libgl
|
|||||||
context = $arg1;
|
context = $arg1;
|
||||||
priority = $arg2;
|
priority = $arg2;
|
||||||
n_ready = $arg3;
|
n_ready = $arg3;
|
||||||
probestr = sprintf("glib.main_context_after_prepare(context=%p) -> priority=%i,n_ready=%u", context, priority, n_ready);
|
probestr = sprintf("glib.main_context_after_prepare(context=%p) -> priority=%i,n_ready=%i", context, priority, n_ready);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -297,7 +297,7 @@ probe glib.main_context_after_query = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib
|
|||||||
timeout = $arg2;
|
timeout = $arg2;
|
||||||
fds = $arg3;
|
fds = $arg3;
|
||||||
n_fds = $arg4;
|
n_fds = $arg4;
|
||||||
probestr = sprintf("glib.main_context_after_query(context=%p) -> timeout=%u,fds=%p,n_fds=%u", context, timeout, fds, n_fds);
|
probestr = sprintf("glib.main_context_after_query(context=%p) -> timeout=%u,fds=%p,n_fds=%d", context, timeout, fds, n_fds);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -313,7 +313,7 @@ probe glib.main_context_before_check = process("@ABS_GLIB_RUNTIME_LIBDIR@/libgli
|
|||||||
max_priority = $arg2;
|
max_priority = $arg2;
|
||||||
fds = $arg3;
|
fds = $arg3;
|
||||||
n_fds = $arg4;
|
n_fds = $arg4;
|
||||||
probestr = sprintf("glib.main_context_before_check(context=%p, max_priority=%i, fds=%p, n_fds=%u)", context, max_priority, fds, n_fds);
|
probestr = sprintf("glib.main_context_before_check(context=%p, max_priority=%i, fds=%p, n_fds=%i)", context, max_priority, fds, n_fds);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -325,7 +325,7 @@ probe glib.main_context_after_check = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib
|
|||||||
{
|
{
|
||||||
context = $arg1;
|
context = $arg1;
|
||||||
n_ready = $arg2;
|
n_ready = $arg2;
|
||||||
probestr = sprintf("glib.main_context_after_check(context=%p) -> %u", context, n_ready);
|
probestr = sprintf("glib.main_context_after_check(context=%p) -> %d", context, n_ready);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -425,7 +425,7 @@ probe glib.idle_dispatch = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@
|
|||||||
func = $arg3;
|
func = $arg3;
|
||||||
data = $arg4;
|
data = $arg4;
|
||||||
again = $arg5;
|
again = $arg5;
|
||||||
probestr = sprintf("glib.idle_dispatch(%p) -> %p, %p, %p, %u", source, context, func, data, again);
|
probestr = sprintf("glib.idle_dispatch(%p) -> %p, %p, %p, %d", source, context, func, data, again);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -465,7 +465,7 @@ probe glib.timeout_dispatch = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.
|
|||||||
func = $arg3;
|
func = $arg3;
|
||||||
data = $arg4;
|
data = $arg4;
|
||||||
again = $arg5;
|
again = $arg5;
|
||||||
probestr = sprintf("glib.timeout_dispatch(%p) -> %p, %p, %p, %u", source, context, func, data, again);
|
probestr = sprintf("glib.timeout_dispatch(%p) -> %p, %p, %p, %d", source, context, func, data, again);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -613,7 +613,7 @@ probe glib.rcbox_alloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT
|
|||||||
n_bytes = $arg2;
|
n_bytes = $arg2;
|
||||||
atomic = $arg3;
|
atomic = $arg3;
|
||||||
zeroed = $arg4;
|
zeroed = $arg4;
|
||||||
probestr = sprintf("glib.rcbox_alloc(n_bytes=%d) -> %p", n_bytes, mem);
|
probestr = sprintf("glib.rcbox_alloc(n_bytes=%u) -> %p", n_bytes, mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -1,14 +1,14 @@
|
|||||||
provider glib {
|
provider glib {
|
||||||
probe mem__alloc(void*, unsigned int, unsigned int, unsigned int);
|
probe mem__alloc(void*, size_t, unsigned int, unsigned int);
|
||||||
probe mem__realloc(void*, void *, unsigned int, unsigned int);
|
probe mem__realloc(void*, void *, size_t, unsigned int);
|
||||||
probe mem__free(void*);
|
probe mem__free(void*);
|
||||||
probe slice__alloc(void*, unsigned int);
|
probe slice__alloc(void*, size_t);
|
||||||
probe slice__free(void*, unsigned int);
|
probe slice__free(void*, size_t);
|
||||||
probe quark__new(const char *, unsigned int);
|
probe quark__new(const char *, unsigned int);
|
||||||
probe main__after_prepare(void*, void*, unsigned int);
|
probe main__after_prepare(void*, void*, int);
|
||||||
probe main__after_check(void*, void*, unsigned int);
|
probe main__after_check(void*, void*, int);
|
||||||
probe main__before_dispatch(const char*, void*, void*, void*, void*);
|
probe main__before_dispatch(const char*, void*, void*, void*, void*);
|
||||||
probe main__after_dispatch(const char*, void*, void*, unsigned int);
|
probe main__after_dispatch(const char*, void*, void*, int);
|
||||||
probe main__source_attach(const char*, void*, void*, unsigned int);
|
probe main__source_attach(const char*, void*, void*, unsigned int);
|
||||||
probe main__source_destroy(const char*, void*, void*);
|
probe main__source_destroy(const char*, void*, void*);
|
||||||
probe main__context_default(void*);
|
probe main__context_default(void*);
|
||||||
@@ -19,11 +19,11 @@ provider glib {
|
|||||||
probe main__context_push_thread_default(void*);
|
probe main__context_push_thread_default(void*);
|
||||||
probe main__context_pop_thread_default(void*);
|
probe main__context_pop_thread_default(void*);
|
||||||
probe main__context_before_prepare(void*);
|
probe main__context_before_prepare(void*);
|
||||||
probe main__context_after_prepare(void*, int, unsigned int);
|
probe main__context_after_prepare(void*, int, int);
|
||||||
probe main__context_before_query(void*, int);
|
probe main__context_before_query(void*, int);
|
||||||
probe main__context_after_query(void*, unsigned int, void*, unsigned int);
|
probe main__context_after_query(void*, int64_t, void*, int);
|
||||||
probe main__context_before_check(void*, int, void*, unsigned int);
|
probe main__context_before_check(void*, int, void*, int);
|
||||||
probe main__context_after_check(void*, unsigned int);
|
probe main__context_after_check(void*, int);
|
||||||
probe main__context_before_dispatch(void*);
|
probe main__context_before_dispatch(void*);
|
||||||
probe main__context_after_dispatch(void*);
|
probe main__context_after_dispatch(void*);
|
||||||
probe main__context_wakeup(void*);
|
probe main__context_wakeup(void*);
|
||||||
@@ -31,19 +31,19 @@ provider glib {
|
|||||||
probe main__loop_new(void*, void*);
|
probe main__loop_new(void*, void*);
|
||||||
probe main__loop_quit(void*);
|
probe main__loop_quit(void*);
|
||||||
probe idle__add(void*, void*, unsigned int, int, void*, void*);
|
probe idle__add(void*, void*, unsigned int, int, void*, void*);
|
||||||
probe idle__dispatch(void*, void*, void*, void*, unsigned int);
|
probe idle__dispatch(void*, void*, void*, void*, int);
|
||||||
probe timeout__add(void*, void*, unsigned int, int, unsigned int, void*, void*);
|
probe timeout__add(void*, void*, unsigned int, int, unsigned int, void*, void*);
|
||||||
probe timeout__dispatch(void*, void*, void*, void*, unsigned int);
|
probe timeout__dispatch(void*, void*, void*, void*, int);
|
||||||
probe source__new(void*, void*, void*, void*, void*, size_t);
|
probe source__new(void*, void*, void*, void*, void*, unsigned int);
|
||||||
probe source__set_callback(void*, void*, void*, void*);
|
probe source__set_callback(void*, void*, void*, void*);
|
||||||
probe source__set_callback_indirect(void*, void*, void*, void*, void*);
|
probe source__set_callback_indirect(void*, void*, void*, void*, void*);
|
||||||
probe source__set_ready_time(void*, unsigned int);
|
probe source__set_ready_time(void*, int64_t);
|
||||||
probe source__set_priority(void*, void*, unsigned int);
|
probe source__set_priority(void*, void*, int);
|
||||||
probe source__add_child_source(void*, void*);
|
probe source__add_child_source(void*, void*);
|
||||||
probe source__set_name(void*, const char*);
|
probe source__set_name(void*, const char*);
|
||||||
probe source__before_free(void*, void*, void*);
|
probe source__before_free(void*, void*, void*);
|
||||||
probe thread__spawned(void*, void*, char*);
|
probe thread__spawned(void*, void*, char*);
|
||||||
probe rcbox__alloc(void*, unsigned int, unsigned int, unsigned int);
|
probe rcbox__alloc(void*, size_t, int, int);
|
||||||
probe rcbox__acquire(void*, unsigned int);
|
probe rcbox__acquire(void*, unsigned int);
|
||||||
probe rcbox__release(void*, unsigned int);
|
probe rcbox__release(void*, unsigned int);
|
||||||
probe rcbox__free(void*);
|
probe rcbox__free(void*);
|
||||||
|
18
glib/gmem.c
18
glib/gmem.c
@@ -98,7 +98,7 @@ g_malloc (gsize n_bytes)
|
|||||||
gpointer mem;
|
gpointer mem;
|
||||||
|
|
||||||
mem = malloc (n_bytes);
|
mem = malloc (n_bytes);
|
||||||
TRACE (GLIB_MEM_ALLOC((void*) mem, (unsigned int) n_bytes, 0, 0));
|
TRACE (GLIB_MEM_ALLOC ((void *) mem, n_bytes, 0, 0));
|
||||||
if (mem)
|
if (mem)
|
||||||
return mem;
|
return mem;
|
||||||
|
|
||||||
@@ -106,7 +106,7 @@ g_malloc (gsize n_bytes)
|
|||||||
G_STRLOC, n_bytes);
|
G_STRLOC, n_bytes);
|
||||||
}
|
}
|
||||||
|
|
||||||
TRACE(GLIB_MEM_ALLOC((void*) NULL, (int) n_bytes, 0, 0));
|
TRACE (GLIB_MEM_ALLOC ((void *) NULL, n_bytes, 0, 0));
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
@@ -131,7 +131,7 @@ g_malloc0 (gsize n_bytes)
|
|||||||
gpointer mem;
|
gpointer mem;
|
||||||
|
|
||||||
mem = calloc (1, n_bytes);
|
mem = calloc (1, n_bytes);
|
||||||
TRACE (GLIB_MEM_ALLOC((void*) mem, (unsigned int) n_bytes, 1, 0));
|
TRACE (GLIB_MEM_ALLOC ((void *) mem, n_bytes, 1, 0));
|
||||||
if (mem)
|
if (mem)
|
||||||
return mem;
|
return mem;
|
||||||
|
|
||||||
@@ -139,7 +139,7 @@ g_malloc0 (gsize n_bytes)
|
|||||||
G_STRLOC, n_bytes);
|
G_STRLOC, n_bytes);
|
||||||
}
|
}
|
||||||
|
|
||||||
TRACE(GLIB_MEM_ALLOC((void*) NULL, (int) n_bytes, 1, 0));
|
TRACE (GLIB_MEM_ALLOC ((void *) NULL, n_bytes, 1, 0));
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
@@ -169,7 +169,7 @@ g_realloc (gpointer mem,
|
|||||||
if (G_LIKELY (n_bytes))
|
if (G_LIKELY (n_bytes))
|
||||||
{
|
{
|
||||||
newmem = realloc (mem, n_bytes);
|
newmem = realloc (mem, n_bytes);
|
||||||
TRACE (GLIB_MEM_REALLOC((void*) newmem, (void*)mem, (unsigned int) n_bytes, 0));
|
TRACE (GLIB_MEM_REALLOC ((void *) newmem, (void *) mem, n_bytes, 0));
|
||||||
if (newmem)
|
if (newmem)
|
||||||
return newmem;
|
return newmem;
|
||||||
|
|
||||||
@@ -320,7 +320,7 @@ g_try_malloc (gsize n_bytes)
|
|||||||
else
|
else
|
||||||
mem = NULL;
|
mem = NULL;
|
||||||
|
|
||||||
TRACE (GLIB_MEM_ALLOC((void*) mem, (unsigned int) n_bytes, 0, 1));
|
TRACE (GLIB_MEM_ALLOC ((void *) mem, n_bytes, 0, 1));
|
||||||
|
|
||||||
return mem;
|
return mem;
|
||||||
}
|
}
|
||||||
@@ -375,7 +375,7 @@ g_try_realloc (gpointer mem,
|
|||||||
free (mem);
|
free (mem);
|
||||||
}
|
}
|
||||||
|
|
||||||
TRACE (GLIB_MEM_REALLOC((void*) newmem, (void*)mem, (unsigned int) n_bytes, 1));
|
TRACE (GLIB_MEM_REALLOC ((void *) newmem, (void *) mem, n_bytes, 1));
|
||||||
|
|
||||||
return newmem;
|
return newmem;
|
||||||
}
|
}
|
||||||
@@ -647,7 +647,7 @@ g_aligned_alloc (gsize n_blocks,
|
|||||||
|
|
||||||
if (G_UNLIKELY (real_size == 0))
|
if (G_UNLIKELY (real_size == 0))
|
||||||
{
|
{
|
||||||
TRACE(GLIB_MEM_ALLOC((void*) NULL, (int) real_size, 0, 0));
|
TRACE (GLIB_MEM_ALLOC ((void *) NULL, real_size, 0, 0));
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -685,7 +685,7 @@ g_aligned_alloc (gsize n_blocks,
|
|||||||
# error "This platform does not have an aligned memory allocator."
|
# error "This platform does not have an aligned memory allocator."
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
TRACE (GLIB_MEM_ALLOC((void*) res, (unsigned int) real_size, 0, 0));
|
TRACE (GLIB_MEM_ALLOC ((void *) res, real_size, 0, 0));
|
||||||
if (res)
|
if (res)
|
||||||
return res;
|
return res;
|
||||||
|
|
||||||
|
@@ -23,8 +23,9 @@
|
|||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#include <string.h>
|
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
#include <stdint.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
#include "../glib/glib-private.h"
|
#include "../glib/glib-private.h"
|
||||||
|
|
||||||
@@ -4625,7 +4626,7 @@ retry:
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
TRACE (GOBJECT_OBJECT_REF (object, G_TYPE_FROM_INSTANCE (object), old_ref));
|
TRACE (GOBJECT_OBJECT_REF (object, (uintmax_t) G_TYPE_FROM_INSTANCE (object), old_ref));
|
||||||
|
|
||||||
*out_toggle_notify = toggle_notify;
|
*out_toggle_notify = toggle_notify;
|
||||||
*out_toggle_data = toggle_data;
|
*out_toggle_data = toggle_data;
|
||||||
@@ -4769,7 +4770,7 @@ retry_beginning:
|
|||||||
goto retry_beginning;
|
goto retry_beginning;
|
||||||
|
|
||||||
/* Beware: object might be a dangling pointer. */
|
/* Beware: object might be a dangling pointer. */
|
||||||
TRACE (GOBJECT_OBJECT_UNREF (object, obj_gtype, old_ref));
|
TRACE (GOBJECT_OBJECT_UNREF (object, (uintmax_t) obj_gtype, old_ref));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4828,9 +4829,9 @@ retry_beginning:
|
|||||||
g_object_notify_queue_freeze (object, TRUE);
|
g_object_notify_queue_freeze (object, TRUE);
|
||||||
nqueue_is_frozen = TRUE;
|
nqueue_is_frozen = TRUE;
|
||||||
|
|
||||||
TRACE (GOBJECT_OBJECT_DISPOSE (object, G_TYPE_FROM_INSTANCE (object), 1));
|
TRACE (GOBJECT_OBJECT_DISPOSE (object, (uintmax_t) G_TYPE_FROM_INSTANCE (object), 1));
|
||||||
G_OBJECT_GET_CLASS (object)->dispose (object);
|
G_OBJECT_GET_CLASS (object)->dispose (object);
|
||||||
TRACE (GOBJECT_OBJECT_DISPOSE_END (object, G_TYPE_FROM_INSTANCE (object), 1));
|
TRACE (GOBJECT_OBJECT_DISPOSE_END (object, (uintmax_t) G_TYPE_FROM_INSTANCE (object), 1));
|
||||||
|
|
||||||
/* Must re-fetch old-ref. _object_unref_clear_weak_locations() relies on
|
/* Must re-fetch old-ref. _object_unref_clear_weak_locations() relies on
|
||||||
* that. */
|
* that. */
|
||||||
@@ -4899,9 +4900,9 @@ retry_decrement:
|
|||||||
g_signal_handlers_destroy (object);
|
g_signal_handlers_destroy (object);
|
||||||
g_object_weak_release_all (object, TRUE);
|
g_object_weak_release_all (object, TRUE);
|
||||||
|
|
||||||
TRACE (GOBJECT_OBJECT_FINALIZE (object, G_TYPE_FROM_INSTANCE (object)));
|
TRACE (GOBJECT_OBJECT_FINALIZE (object, (uintmax_t) G_TYPE_FROM_INSTANCE (object)));
|
||||||
G_OBJECT_GET_CLASS (object)->finalize (object);
|
G_OBJECT_GET_CLASS (object)->finalize (object);
|
||||||
TRACE (GOBJECT_OBJECT_FINALIZE_END (object, G_TYPE_FROM_INSTANCE (object)));
|
TRACE (GOBJECT_OBJECT_FINALIZE_END (object, (uintmax_t) G_TYPE_FROM_INSTANCE (object)));
|
||||||
|
|
||||||
GOBJECT_IF_DEBUG (OBJECTS,
|
GOBJECT_IF_DEBUG (OBJECTS,
|
||||||
{
|
{
|
||||||
|
@@ -1,13 +1,13 @@
|
|||||||
provider gobject {
|
provider gobject {
|
||||||
probe type__new(char *, unsigned long, unsigned long);
|
probe type__new(char *, uintmax_t, uintmax_t);
|
||||||
probe object__new(void*, unsigned long);
|
probe object__new(void*, uintmax_t);
|
||||||
probe object__ref(void*, unsigned long, unsigned int);
|
probe object__ref(void*, uintmax_t, int);
|
||||||
probe object__unref(void*, unsigned long, unsigned int);
|
probe object__unref(void*, uintmax_t, int);
|
||||||
probe object__dispose(void*, unsigned long, unsigned int);
|
probe object__dispose(void*, uintmax_t, unsigned int);
|
||||||
probe object__dispose__end(void*, unsigned long, unsigned int);
|
probe object__dispose__end(void*, uintmax_t, unsigned int);
|
||||||
probe object__finalize(void*, unsigned long);
|
probe object__finalize(void*, uintmax_t);
|
||||||
probe object__finalize__end(void*, unsigned long);
|
probe object__finalize__end(void*, uintmax_t);
|
||||||
probe signal__new(unsigned int, char *, unsigned long);
|
probe signal__new(unsigned int, char *, uintmax_t);
|
||||||
probe signal__emit(unsigned int, unsigned int, void *, unsigned long);
|
probe signal__emit(unsigned int, unsigned int, void *, uintmax_t);
|
||||||
probe signal__emit__end(unsigned int, unsigned int, void *, unsigned long);
|
probe signal__emit__end(unsigned int, unsigned int, void *, uintmax_t);
|
||||||
};
|
};
|
||||||
|
@@ -26,8 +26,9 @@
|
|||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#include <string.h>
|
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
#include <stdint.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
#include "gsignal.h"
|
#include "gsignal.h"
|
||||||
#include "gtype-private.h"
|
#include "gtype-private.h"
|
||||||
@@ -1694,7 +1695,7 @@ g_signal_newv (const gchar *signal_name,
|
|||||||
key.quark = g_quark_from_string (name);
|
key.quark = g_quark_from_string (name);
|
||||||
g_signal_key_bsa = g_bsearch_array_insert (g_signal_key_bsa, &g_signal_key_bconfig, &key);
|
g_signal_key_bsa = g_bsearch_array_insert (g_signal_key_bsa, &g_signal_key_bconfig, &key);
|
||||||
|
|
||||||
TRACE(GOBJECT_SIGNAL_NEW(signal_id, name, itype));
|
TRACE (GOBJECT_SIGNAL_NEW (signal_id, name, (uintmax_t) itype));
|
||||||
}
|
}
|
||||||
node->destroyed = FALSE;
|
node->destroyed = FALSE;
|
||||||
|
|
||||||
@@ -3415,7 +3416,7 @@ signal_emit_valist_unlocked (gpointer instance,
|
|||||||
|
|
||||||
if (closure != NULL)
|
if (closure != NULL)
|
||||||
{
|
{
|
||||||
TRACE(GOBJECT_SIGNAL_EMIT(signal_id, detail, instance, instance_type));
|
TRACE (GOBJECT_SIGNAL_EMIT (signal_id, detail, instance, (uintmax_t) instance_type));
|
||||||
|
|
||||||
SIGNAL_UNLOCK ();
|
SIGNAL_UNLOCK ();
|
||||||
|
|
||||||
@@ -3485,7 +3486,7 @@ signal_emit_valist_unlocked (gpointer instance,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
TRACE(GOBJECT_SIGNAL_EMIT_END(signal_id, detail, instance, instance_type));
|
TRACE (GOBJECT_SIGNAL_EMIT_END (signal_id, detail, instance, (uintmax_t) instance_type));
|
||||||
|
|
||||||
/* See comment above paired ref above */
|
/* See comment above paired ref above */
|
||||||
#ifndef __COVERITY__
|
#ifndef __COVERITY__
|
||||||
|
@@ -481,7 +481,7 @@ type_node_any_new_W (TypeNode *pnode,
|
|||||||
pnode->children[i] = type;
|
pnode->children[i] = type;
|
||||||
}
|
}
|
||||||
|
|
||||||
TRACE(GOBJECT_TYPE_NEW(name, node->supers[1], type));
|
TRACE (GOBJECT_TYPE_NEW (name, node->supers[1], (uintmax_t) type));
|
||||||
|
|
||||||
node->plugin = plugin;
|
node->plugin = plugin;
|
||||||
node->n_children = 0;
|
node->n_children = 0;
|
||||||
@@ -1906,7 +1906,7 @@ g_type_create_instance (GType type)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
TRACE(GOBJECT_OBJECT_NEW(instance, type));
|
TRACE (GOBJECT_OBJECT_NEW (instance, (uintmax_t) type));
|
||||||
|
|
||||||
return instance;
|
return instance;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user