blob: 3f369e5f976b724232e4cf4a4f9fe1e90782dbe0 [file] [log] [blame]
Jeff Dike4b84c692006-09-25 23:33:04 -07001/*
2 * Copyright (C) 2006 Jeff Dike (jdike@addtoit.com)
3 * Licensed under the GPL
4 */
5
6#include <signal.h>
7
8extern void (*handlers[])(int sig, struct sigcontext *sc);
9
10void hard_handler(int sig)
11{
12 struct ucontext *uc;
13 asm("movq %%rdx, %0" : "=r" (uc));
14
15 (*handlers[sig])(sig, (struct sigcontext *) &uc->uc_mcontext);
16}