Rev 3788 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3788 | Rev 3832 | ||
---|---|---|---|
Line 46... | Line 46... | ||
46 | 46 | ||
47 | #define fault_if_from_uspace(istate, fmt, ...) \ |
47 | #define fault_if_from_uspace(istate, fmt, ...) \ |
48 | { \ |
48 | { \ |
49 | if (istate_from_uspace(istate)) { \ |
49 | if (istate_from_uspace(istate)) { \ |
50 | task_t *task = TASK; \ |
50 | task_t *task = TASK; \ |
51 | printf("Task %" PRIu64 " killed due to an exception at %p.", task->taskid, istate_get_pc(istate)); \ |
51 | printf("Task %s (%" PRIu64 ") killed due to an exception at %p: ", task->name, task->taskid, istate_get_pc(istate)); \ |
52 | printf(" " fmt "\n", ##__VA_ARGS__); \ |
52 | printf(fmt "\n", ##__VA_ARGS__); \ |
53 | task_kill(task->taskid); \ |
53 | task_kill(task->taskid); \ |
54 | thread_exit(); \ |
54 | thread_exit(); \ |
55 | } \ |
55 | } \ |
56 | } |
56 | } |
57 | 57 |