of an incompatible type to signal handler.
Untyped function pointer sa_handler() is no longer available
so we leverage sa_sigaction(int, siginfo_t *, void *) instead.
n-i-bz
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15858
static ucontext_t uc;
static float inhandler[8];
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
int i;
+ ucontext_t *ucp = (ucontext_t *) arg;
si = *sip;
uc = *ucp;
float *px = malloc(sizeof(*px));
x0 = px[0];
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:96)
+ at 0x........: main (context_fpu.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:96)
+ at 0x........: main (context_fpu.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:96)
+ at 0x........: main (context_fpu.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:96)
+ at 0x........: main (context_fpu.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:96)
+ at 0x........: main (context_fpu.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:96)
+ at 0x........: main (context_fpu.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:96)
+ at 0x........: main (context_fpu.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:96)
+ at 0x........: main (context_fpu.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:104)
+ at 0x........: main (context_fpu.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:104)
+ at 0x........: main (context_fpu.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:104)
+ at 0x........: main (context_fpu.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:104)
+ at 0x........: main (context_fpu.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:104)
+ at 0x........: main (context_fpu.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:104)
+ at 0x........: main (context_fpu.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:104)
+ at 0x........: main (context_fpu.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:104)
+ at 0x........: main (context_fpu.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:50)
+ by 0x........: main (context_fpu.c:51)
void break_out(void);
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
+ ucontext_t *ucp = (ucontext_t *) arg;
+
si = *sip;
uc = *ucp;
long *py = malloc(sizeof(*py));
y0 = py[0];
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_gpr.c:84)
+ at 0x........: main (context_gpr.c:86)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_gpr.c:43)
+ by 0x........: main (context_gpr.c:45)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_gpr.c:91)
+ at 0x........: main (context_gpr.c:93)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_gpr.c:43)
+ by 0x........: main (context_gpr.c:45)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_gpr.c:91)
+ at 0x........: main (context_gpr.c:93)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_gpr.c:39)
+ by 0x........: main (context_gpr.c:41)
static siginfo_t si;
static ucontext_t uc;
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
si = *sip;
- uc = *ucp;
+ uc = *((ucontext_t *) arg);
}
int main(void)
pid_t pid;
long rflags;
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
void break_out(void);
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
+ ucontext_t *ucp = (ucontext_t *) arg;
+
si = *sip;
uc = *ucp;
int *px = malloc(sizeof(*px));
x1 = px[0] + 1;
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_rflags2.c:86)
+ at 0x........: main (context_rflags2.c:88)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_rflags2.c:45)
+ by 0x........: main (context_rflags2.c:47)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_rflags2.c:86)
+ at 0x........: main (context_rflags2.c:88)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_rflags2.c:45)
+ by 0x........: main (context_rflags2.c:47)
static upad128_t x0;
static upad128_t d0 = {0};
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
+ ucontext_t *ucp = (ucontext_t *) arg;
+
si = *sip;
uc = *ucp;
upad128_t *py = malloc(sizeof(*py));
y0 = py[0];
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:95)
+ at 0x........: main (context_sse.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:95)
+ at 0x........: main (context_sse.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:95)
+ at 0x........: main (context_sse.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:95)
+ at 0x........: main (context_sse.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:95)
+ at 0x........: main (context_sse.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:95)
+ at 0x........: main (context_sse.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:95)
+ at 0x........: main (context_sse.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:95)
+ at 0x........: main (context_sse.c:97)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:103)
+ at 0x........: main (context_sse.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:45)
+ by 0x........: main (context_sse.c:47)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:103)
+ at 0x........: main (context_sse.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:45)
+ by 0x........: main (context_sse.c:47)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:103)
+ at 0x........: main (context_sse.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:103)
+ at 0x........: main (context_sse.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:103)
+ at 0x........: main (context_sse.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:103)
+ at 0x........: main (context_sse.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:103)
+ at 0x........: main (context_sse.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:103)
+ at 0x........: main (context_sse.c:105)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:49)
+ by 0x........: main (context_sse.c:51)
static volatile int *sp;
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
+ ucontext_t *ucp = (ucontext_t *) arg;
sp = (int *) &ucp->uc_mcontext.gregs[0];
}
volatile int zero = 0;
/* Setup a signal handler. */
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Invalid read of size 4
- at 0x........: main (context_stack_die.c:38)
+ at 0x........: main (context_stack_die.c:39)
Address 0x........ is on thread 1's stack
.... bytes below stack pointer
static siginfo_t si;
static ucontext_t uc;
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
si = *sip;
- uc = *ucp;
+ uc = *((ucontext_t *) arg);
}
int main(void)
pid_t pid;
int eflags;
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
void break_out(void);
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
+ ucontext_t *ucp = (ucontext_t *) arg;
+
si = *sip;
uc = *ucp;
int *px = malloc(sizeof(*px));
x1 = px[0] + 1;
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_eflags2.c:76)
+ at 0x........: main (context_eflags2.c:78)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_eflags2.c:36)
+ by 0x........: main (context_eflags2.c:38)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_eflags2.c:76)
+ at 0x........: main (context_eflags2.c:78)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_eflags2.c:36)
+ by 0x........: main (context_eflags2.c:38)
static ucontext_t uc;
static float inhandler[8];
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
int i;
+ ucontext_t *ucp = (ucontext_t *) arg;
si = *sip;
uc = *ucp;
float *px = malloc(sizeof(*px));
x0 = px[0];
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:103)
+ at 0x........: main (context_fpu.c:104)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:103)
+ at 0x........: main (context_fpu.c:104)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:103)
+ at 0x........: main (context_fpu.c:104)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:103)
+ at 0x........: main (context_fpu.c:104)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:103)
+ at 0x........: main (context_fpu.c:104)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:103)
+ at 0x........: main (context_fpu.c:104)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:103)
+ at 0x........: main (context_fpu.c:104)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:103)
+ at 0x........: main (context_fpu.c:104)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:111)
+ at 0x........: main (context_fpu.c:112)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:111)
+ at 0x........: main (context_fpu.c:112)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:111)
+ at 0x........: main (context_fpu.c:112)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:111)
+ at 0x........: main (context_fpu.c:112)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:111)
+ at 0x........: main (context_fpu.c:112)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:111)
+ at 0x........: main (context_fpu.c:112)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:111)
+ at 0x........: main (context_fpu.c:112)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_fpu.c:111)
+ at 0x........: main (context_fpu.c:112)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_fpu.c:49)
+ by 0x........: main (context_fpu.c:50)
/* x0 is always zero, but is visible to Valgrind as uninitialised. */
static int x0;
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
+ ucontext_t *ucp = (ucontext_t *) arg;
+
si = *sip;
uc = *ucp;
int *py = malloc(sizeof(*py));
y0 = py[0];
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_gpr.c:81)
+ at 0x........: main (context_gpr.c:83)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_gpr.c:37)
+ by 0x........: main (context_gpr.c:39)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_gpr.c:88)
+ at 0x........: main (context_gpr.c:90)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_gpr.c:37)
+ by 0x........: main (context_gpr.c:39)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_gpr.c:88)
+ at 0x........: main (context_gpr.c:90)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_gpr.c:33)
+ by 0x........: main (context_gpr.c:35)
static upad128_t x0;
static upad128_t d0 = {0};
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
+ ucontext_t *ucp = (ucontext_t *) arg;
+
si = *sip;
uc = *ucp;
upad128_t *py = malloc(sizeof(*py));
y0 = py[0];
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:101)
+ at 0x........: main (context_sse.c:103)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:101)
+ at 0x........: main (context_sse.c:103)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:101)
+ at 0x........: main (context_sse.c:103)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:101)
+ at 0x........: main (context_sse.c:103)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:101)
+ at 0x........: main (context_sse.c:103)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:101)
+ at 0x........: main (context_sse.c:103)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:101)
+ at 0x........: main (context_sse.c:103)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:101)
+ at 0x........: main (context_sse.c:103)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:109)
+ at 0x........: main (context_sse.c:111)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:43)
+ by 0x........: main (context_sse.c:45)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:109)
+ at 0x........: main (context_sse.c:111)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:43)
+ by 0x........: main (context_sse.c:45)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:109)
+ at 0x........: main (context_sse.c:111)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:109)
+ at 0x........: main (context_sse.c:111)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:109)
+ at 0x........: main (context_sse.c:111)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:109)
+ at 0x........: main (context_sse.c:111)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:109)
+ at 0x........: main (context_sse.c:111)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
Conditional jump or move depends on uninitialised value(s)
- at 0x........: main (context_sse.c:109)
+ at 0x........: main (context_sse.c:111)
Uninitialised value was created by a heap allocation
at 0x........: malloc (vg_replace_malloc.c:...)
- by 0x........: main (context_sse.c:47)
+ by 0x........: main (context_sse.c:49)
#include <stdio.h>
#include <ucontext.h>
-static void sighandler(int sig, siginfo_t *sip, ucontext_t *ucp)
+static void sighandler(int sig, siginfo_t *sip, void *arg)
{
ucontext_t uc2;
- /* Current uc_link value has to be equal to ucp. */
+ /* Current uc_link value has to be equal to (ucontext_t *) arg. */
getcontext(&uc2);
- assert(uc2.uc_link == ucp);
+ assert(uc2.uc_link == arg);
}
int main(void)
}
assert(!uc.uc_link);
- sa.sa_handler = sighandler;
+ sa.sa_sigaction = sighandler;
sa.sa_flags = SA_SIGINFO;
if (sigfillset(&sa.sa_mask)) {
perror("sigfillset");